Tuesday, August 16, 2005

Flash® 8 - External Interface Example

Darron Schall completed a custom projector in C# wrapping Flash® Player 8 for Flash® by Example. Flash® 8 supports a new data exchange model called External Interface to allow for synchronous exchange of data.&

External Interface allows you to call functions in external applications (browser, JavaScript, VBScript, C#) and synchronously receive the returned data into Flash®. Likewise you can call functions within a SWF file from an external application.



In this example, Darron enabled External Interface to exchange data with C#. The example reads file data from a local drive and renders it into a V2 Tree control. Clicking on a directory in the v2 tree will display a file listing of the directory into a V2 DataGrid. Also when the C# app detects loss of focus, it disables the controls within the SWF.

The example is quite impressive and provides the base code for a custom projector shell. The example includes full C# and FLA source code.

This example will be added to Flash(R) by Example when Macromedia® Flash® 8 ships.

More to come,

Ted :)

1 Comments:

At August 16, 2005 8:11 AM, Ted Patrick said...

I forgot to add the file size information as follows:

ExternalInterface.exe 24Kb
AxInterop.ShockwaveFlashObjects.dll 28Kb
Interop.ShockwaveFlashObjects.dll 32Kb
DirectoryBrowser.swf 66Kb

Total: 149Kb + .Net Runtime

The SWF file is larger than the projector.

Cheers,

ted ;)

 

Post a Comment

<< Home