Flash Authoring Notes 01 04 April 2003
The graphical block below is a Flash movie that loads entire articles dynamically from separate plain-text files. The file size of the Flash movie is 8 KB.
This allows authors to create simple documents, which may include HTML styling such as boldface and italics -- and even hyperlinks -- without using Flash at all.
The green triangle opens the menu. Each button on the menu loads a different text file.

The plain-text files include four simple field names:

  • headingdata
  • bylinedata
  • articledata
  • notedata
Open article01.txt to see the formatting used.

The text following each of these field names (in the text file) is loaded by Flash into a separate, named text field in the Flash movie above.

You can dissect this Flash movie's Timeline and ActionScript
in the Interactive Timeline Movie.

The ActionScript that initially loads the file:
myData = new LoadVars();
myData.load("article01.txt");

To load a different text file, e.g. from a button click:
myData.load("article02.txt");

To make a dynamic text field recognize HTML, use these two lines to load the text into the field (here, it is a text field with the Instance Name "byline"):
byline.html = true;
byline.htmlText = myData.bylinedata;

The menu appears when the playhead moves to a place in the Timeline where the menu is visible. The "close" button for the menu moves the playhead back to the beginning.

Page and text copyright © 2003 by Mindy McAdams.
> Flash Examples Index