4 Replies Latest reply on Apr 17, 2007 12:54 AM by Greg Dove

    Opening External Files using SWF

    sai1
      Hi all,

      Is there a way to open external files using swf? I have gone through a number of forums and all seem to tell me to open with a window projector. my problem is, I need to embed the swf into a html to be viewed online... So I need to do it in swf format.

      Any ideas?

        • 1. Re: Opening External Files using SWF
          kglad Adobe Community Professional & MVP
          check the filereference class.
          • 2. Re: Opening External Files using SWF
            sai1 Level 1
            What do you mean file reference class? I went to F1 help, but there's no file reference class written. Can you elaborate please? Many thanks.
            • 3. Re: Opening External Files using SWF
              kglad Adobe Community Professional & MVP
              in the help files: actionscript 2.0 language reference/actionscript classes/filereference.

              or:

              http://livedocs.adobe.com/flash/8/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveD ocs_Parts&file=00002204.html
              • 4. Re: Opening External Files using SWF
                Greg Dove Level 4
                When you say 'external files' I presume you mean local files on the users hard drive.

                If that's true:

                When you say 'open' what do you mean? It could mean to open and load a text file/xml file or another swf in flash or it could mean to launch a document in its native application e.g. .doc launches word etc. Flash projectors can do the first thing, but not the second thing. And you need to know the path of the file because I don't believe you can retreive it from the filereference browsing support. 3rd party tools are necessary to really add a lot of file system support to projector applications, and then you can do both things mentioned here, without the limitations of flash player security which is only slightly reduced with regular projector files.

                The filereference class in flash is primarily for upload/download support. You can't 'open' local files with it. There is, to my current knowledge, no way you can do that with flash in a html page directly.

                The only way I can think that it might be possible (untested) would be to have a separate local MS Office (or any other host for a flash activex that gives filesystem access) with some embedded flash in a document that (perhaps) could talk via local connection with your html page content and which would in turn talk to its VBA host to request local file system activity. I don't know if this would work because I've not used localconnection, but perhaps it might.