EasyManua.ls Logo

MACROMEDIA FLASH 8-LEARNING ACTIONSCRIPT 2.0 IN FLASH - Page 671

MACROMEDIA FLASH 8-LEARNING ACTIONSCRIPT 2.0 IN FLASH
830 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
About the External API 671
You can find the sample source file, ExtInt.fla, in the Samples folder on your hard disk.
In Windows, browse to boot drive\Program Files\Macromedia\Flash 8\Samples and
Tutorials\Samples\ActionScript\ExternalAPI\simple example.
On the Macintosh, browse to Macintosh HD/Applications/Macromedia Flash 8/Samples
and Tutorials/Samples/ActionScript/ExternalAPI/simple example.
For a more complex example that uses the External API, see “Controlling Flash Video with
the External API” on page 671. For more information on local file security, see About local
file security and Flash Player” on page 679.
Controlling Flash Video with the External API
The following procedure shows you how to control Flash Video (FLV) files using controls in
an HTML page and displays information about the video in an HTML text field. This
procedure uses the External API to achieve this functionality.
To build a Flash application using the External API:
1. Create a new Flash document and save it as video.fla.
2. Add a new video symbol to the library by selecting New Video from the pop-up menu in
the Library panel.
3. Drag the video symbol to the Stage and give it an instance name of selected_video.
4. Select the selected_video instance and then the Property inspector to resize the instance
to 320 pixels wide by 240 pixels high.
5. Set both the x and y coordinates for the video’s position to 0.
6. Select the Stage and use the Property inspector to resize its dimensions to 320 pixels by
240 pixels.
Now the Stage matches the dimensions of the video instance.
NOTE
Avoid using other methods of accessing the plug-in object, such as
document.getElementById("pluginName") or document.all.pluginName, because these
other methods do not work consistently across all browsers.

Table of Contents

Related product manuals