FlashPaper 2 -- links to internal functions
July 4, 2006
Using FlashPaper to quickly convert text into Flash content can seriously speed up your production of Flash applications.
If you use a nice Word template your graphic design doesn't have to suffer either. Excellent!
What -- no internal links?
The hyperlinks you create in FlashPaper, via Word, can only point to different web sites. Wouldn't it be nice to be able to point to internal Flash functions as
well? Having a link that says "start this part of the program" that really works? I think it would, so I've written a small solution for you.
Let us modify the FlashPaper API
The API for FlashPaper 2 has a method
And fortunately Macromedia's programmers use their own API -- they call this method each time you click a link in a FlashPaper document.
In the example below the API of FlashPaper is accessed through the object fpAPI (if you unsure about how to create such an object read Macromedias API
specs, see the link above).
// store original FlashPaperAPI-method
// replace with our own API-method
// use original link-function
// convert hyperlink to function call
Creating internal links in Word
You can now call any function you desire at _root-level in your Flash-application by creating a link in a Word-document:
- Right-click in your Word document and choose Hyperlink.
- Write your link address like this:
When you're happy with your Word document:
- Convert to FlashPaper 2.
- Load the FlashPaper document into your Flash application.
- Try out your links.