A Flash Developer Resource Site

Page 1 of 3 123 LastLast
Results 1 to 20 of 54

Thread: [F8]Does anyone know flashpaper

  1. #1
    Senior Member
    Join Date
    May 2006
    Posts
    111

    [F8]Does anyone know flashpaper

    i used the code provided in flashpaper and i filled in the gaps and i still can't get it to work any advice?
    Mitch The Boss

  2. #2
    FK's Geezer Mod Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    Can't get what to work? Flashpaper works with other apps, like Word, or Excell. Open those, then you see a Flashpaper menu at the top. Click that, then pick what you want to make. If it's a swf, it just makes a swf. You just insert the swf on a html page to use it.

  3. #3
    Senior Member
    Join Date
    May 2006
    Posts
    111
    i would liek to put it in my flash presentation not on a website this presentation is for distribution on cd not online
    Mitch The Boss

  4. #4
    FK's Geezer Mod Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    Once it's made, you can just use loadMovie to load it into another swf, or in your case, an EXE. Everything is contained in the flashpaper swf. Just load it into an empty clip inside the main movie.

  5. #5
    Senior Member
    Join Date
    May 2006
    Posts
    111
    when i try to do that it doesn't show the document it says flash paper but it just flashes a grey screen that doens't make sence.
    Mitch The Boss

  6. #6
    Senior Member
    Join Date
    May 2006
    Posts
    111
    is it possible that it is becasue the document is wider then my presentation becauyse if i drag a scrollbar component into my presentation i can put it in but it looks terrible
    Mitch The Boss

  7. #7
    Senior Member
    Join Date
    May 2006
    Posts
    111
    Code:
    function loadFlashPaper(
       path_s,   // C:\Documents and Settings\mitch\Desktop\R01-2006.swf
       dest_mc,  // box_mc
       width_i,  // 500px
       height_i, // 350px
       loaded_o) // optional:
    {
       var intervalID = 0;
       var loadFunc = function()
       {
          dest_mc._visible = false;
          var fp = dest_mc.getIFlashPaper();
          if (!fp)
             return;
          if (fp.setSize(width_i, height_i) == false)
             return;
          dest_mc._visible = true;
          clearInterval(intervalID);
          loaded_o.onLoaded(fp);
       }
       intervalID = setInterval(loadFunc, 100);
       dest_mc.loadMovie(path_s);
    }
    that is what i am trying to use provided by flashpaper
    Mitch The Boss

  8. #8
    FK's Geezer Mod Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    OK, no, you didn't do the code right. The first line, function loadFlashPaper is just setting up the function parameters. You set them later, when you call the function, which is down in the bottom part, that you didn't include, the bery last line, loadFlashPaper. You also left out some other parts. Here's the whole block of code you need.

    Code:
    function loadFlashPaper(
       path_s, // path of SWF to load
       dest_mc, // MC which we should replace with the SWF
       width_i, // new size of the dest MC
       height_i, // new size of the dest MC
       loaded_o) // optional: object to be notified that loading is complete
    {
       var intervalID = 0;
       var loadFunc = function()
       {
          dest_mc._visible = false;
          var fp = dest_mc.getIFlashPaper();
          if (!fp)
             return;
          if (fp.setSize(width_i, height_i) == false)
             return;
          dest_mc._visible = true;
          clearInterval(intervalID);
          loaded_o.onLoaded(fp);
       }
       intervalID = setInterval(loadFunc, 100);
       dest_mc.loadMovie(path_s);
    }
    function onLoaded(fp)
    {
       // loading is complete, so we can now adjust the current page, zoom, etc.
       // go to page 1.
       fp.setCurrentPage(1);
       // change magnification to 60%
       fp.setCurrentZoom(60);
    }
    loadFlashPaper("Basic_Setup_Directions1.swf", _root.mtClip, 550, 650, this);
    I'll attach my example. But, using this code, I had to put it on a server to see it when testing outside flash. Flashpaper is some kind of component. I think your going to have to use a simple loadMovie on your CD to make this work.
    Attached Files Attached Files

  9. #9
    Senior Member
    Join Date
    May 2006
    Posts
    111
    ok do i apply that to a fram or to a mc that i want it to replace
    Mitch The Boss

  10. #10
    FK's Geezer Mod Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    Apply what? That code? It goes in a frame.

  11. #11
    Senior Member
    Join Date
    May 2006
    Posts
    111
    why does mtClip work when the destination mc is called empty clip
    Mitch The Boss

  12. #12
    Senior Member
    Join Date
    May 2006
    Posts
    111
    i still can't get it to show up i'm not sure what i am doing wrong. i had to put a stop function in because it starts the presentation over otherwise
    Mitch The Boss

  13. #13
    FK's Geezer Mod Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    mtClip is the Instance name. The library names of objects means nothing. If you want to target anything with actionscript it has to have an instance name, or Linkage Identifier once it's onstage.

  14. #14
    Senior Member
    Join Date
    May 2006
    Posts
    111
    so do i click on the movieclip and in properties just change it. thats what i thought but when i looked at your attatched file i couldn't find where you wrote mtClip
    Mitch The Boss

  15. #15
    Senior Member
    Join Date
    May 2006
    Posts
    111
    ok i did that and still nothing. i would like to post it on here but it's too large of a file even compressed
    Mitch The Boss

  16. #16
    Senior Member
    Join Date
    May 2006
    Posts
    111
    this is what i currently have:
    function loadFlashPaper(
    path_s, // path of SWF to load
    dest_mc, // MC which we should replace with the SWF
    width_i, // new size of the dest MC
    height_i, // new size of the dest MC
    loaded_o) // optional: object to be notified that loading is complete
    {
    var intervalID = 0;
    var loadFunc = function()
    {
    dest_mc._visible = false;
    var fp = dest_mc.getIFlashPaper();
    if (!fp)
    return;
    if (fp.setSize(width_i, height_i) == false)
    return;
    dest_mc._visible = true;
    clearInterval(intervalID);
    loaded_o.onLoaded(fp);
    }
    intervalID = setInterval(loadFunc, 100);
    dest_mc.loadMovie(path_s);
    }
    function onLoaded(fp)
    {
    // loading is complete, so we can now adjust the current page, zoom, etc.
    // go to page 50.
    fp.setCurrentPage(1);
    // change magnification to 33%
    fp.setCurrentZoom(60);
    }
    loadFlashPaper("R01-2006.swf", _root.intro.mtClip, 550, 650, this);
    stop();
    Mitch The Boss

  17. #17
    FK's Geezer Mod Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    No, you can't use any of that code if your going to load it into an empty clip. You just have to accept the defaults of the flashpaper component if you want to load it to an empty movie clip inside the main movie. Just use;

    _root.intro.mtClip.loadMovie("R01-2006.swf");

    You give any object an instance name by selecting the object on stage, then look in the left end of the properties panel for a window that says <Instance Name>. Just click in there and type the new name.

  18. #18
    Senior Member
    Join Date
    May 2006
    Posts
    111
    yours was on scene 1 right thats why the code works?
    Mitch The Boss

  19. #19
    Senior Member
    Join Date
    May 2006
    Posts
    111
    that didn't work for me either.... i have been trying to do this for almost a month and i'm stuck until i can do it...
    Mitch The Boss

  20. #20
    FK's Geezer Mod Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    Are you trying this on a CD? I haven't done that, and I'm not sure it will even work. And it doesn't work if you try and load it to another swf, unless it's on a server. I don't know why.

    Here's a link that loads a flashpaper swf into an empty clip;

    http://www.flashbax.com//newtemp/loadpaper2.html

    And here's a page with the raw flashpaper swf embedded on the page.

    http://www.flashbax.com//newtemp/loadpaper1.html

    And I uploaded a zip that shows how to load the flashpaper swf into an empty clip.
    Attached Files Attached Files

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center