A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Need script to open .exe

  1. #1
    Junior Member
    Join Date
    Jan 2010
    Posts
    2

    Need script to open .exe

    Hi, so here's my question. I am developing a software launcher in flash that will open other flash projects compiled as .exe. This will all run off a CD.

    I need a script so that I can create buttons in the launcher that will open the .exe. The link thing only seems to work for flash files not .exe files.

    Thank you.

  2. #2
    Lifetime Friend of Site Staff Northcode's Avatar
    Join Date
    Dec 2000
    Location
    Whitehorse YT
    Posts
    3,766
    Try fscommand("exec", "demo.exe") where demo.exe is located in a folder called fscommand in the root of your CD where your main launcher EXE is sitting. The EXEC command won't work if you try to specify a path or arguments to the EXE file and the EXE file MUST be in the special fscommand folder. See the Flash documentation for details. You might also want to check out the free proxy tool I created if you need to do more than just call an EXE.

  3. #3
    Junior Member
    Join Date
    Jan 2010
    Posts
    2
    Hi Thank you so much for the detailed response. Is there any chance that I can have the .exe files that I'm launching in sub folders. The issue that I'm coming up against is that in addition to an .exe file, each of those has dependent files like javascript and some other crap, all with the same name. If each exe was in the same folder, only one of the exe programs would be able to launch.

    I think that by having them in sub folders, this would resolve the problem. What do you think? Is this possible to use sub folders?

  4. #4
    Lifetime Friend of Site Staff Northcode's Avatar
    Join Date
    Dec 2000
    Location
    Whitehorse YT
    Posts
    3,766
    Not with just an fscommand from Flash, the EXE or BAT file you launch MUST be in the fscommand folder. However, if you launch a BAT file instead of an EXE you can make the BAT file do whatever you like, like launch files from subfolders. If you use my proxy tool you can hide the fact that you're using a BAT file to do your dirty work. That way all the launcher BAT files (and renamed copies of proxy.exe) go in the fscommand folder and the actual applications can be wherever you need them to be. Follow the link to the proxy tool from my last post and play around with it to see how it works and let me know if you run into any problems.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center