Conquering FSCommand EXEC Part 1 : Proxy

 Posted on Tue Aug 7 2007 in Tools by Tim

A typical requirement you'll run across when developing CD based Flash projects is the need to open documents from your Flash projector. You can use getURL to open most documents, but sometimes the document opens behind the projector. The EXEC fscommand could be used to launch a helper application, but unfortunately the EXEC fscommand doesn't allow you to pass parameters to external applications so you have no way to tell the outside world which file you want to open.

You can thank the creators of the first Flash virus (SWF/LFM-926) for the fact that every version of the stand-alone Flash player since Flash MX has restricted the use of the EXEC command. This change made it impossible for anyone to create any new Flash based viruses, but it also crippled the Flash projector as a tool for legitimate users by instantly rendering many free projector extension tools useless.

There are four key restrictions that you have to keep in mind when working with the EXEC fscommand and standalone Flash projectors. (i) Executables you want to run via the EXEC fscommand have to be in a special sandboxed folder called fscommand in the same directory as the projector. (ii) You can't specify a path in the EXEC command, just a filename. If the specified file is not found in the fscommand folder, it won't run. (iii) The only argument allowed by the EXEC fscommand is a filename, there is no way to pass arguments to the executables that you want to run. (iv) You can't use EXEC from an SWF file, it will only work from a projector (EXE). The last restriction doesn't really concern us, but if you're trying to test your EXEC calls, being aware of it will save you some frustration.

Update One additional restriction you will have to deal with is the fact that Flash 9 projectors can't launch BAT files on Windows 2000, XP and Vista.

Important If you use SWF Studio then you don't need to read any further. SWF Studio still supports the Flash EXEC FSCommand but the limitations have been removed. Your SWF Studio projectors will be able to pass arguments to external applications and you won't have to put the executables you want to run in the fscommand sandbox folder. SWF Studio extends Flash with new commands like ssCore.Shell.execute and that make the EXEC fscommand obsolete and give you an unprecedented amount of control over your external applications and documents.

One solution to get around the limitations of the EXEC fscommand is to create one exectuable file for each file that you want to open, but what can you do if you don't know how to make EXE files? Windows and Flash both consider a BAT file as an executable file so the easy solution is to create a BAT file for each file you want to open and EXEC the BAT file from Flash. You don't need to be a BAT file wizard to do this, the simple one-liner below (let's call it mydoc.bat) will do the trick:

start mydoc.pdf

That example assumes that both mydoc.bat and mydoc.pdf are in the fscommand folder. You can change the BAT file to launch the PDF file from anywhere you like, as long as you can create a valid path to the file. Now all you have to do is create a BAT file for every file you want to open and call it from Flash like this:

fscommand("exec", "mydoc.bat");

The only problem with this approach is that your user is going to see the ugly black DOS box appear every time they open a file. That's where the proxy utility can help you create a more professional looking end product for your users. Proxy is able to launch BAT files and suppress the ugly DOS box.

usage: proxy.exe

When you run the proxy utility, the first thing it does is look at its own name, in this case proxy.exe. It then looks for a BAT file in the same directory with the same base name, i.e. proxy.bat, and runs that BAT file. If you rename the proxy utility to xyz.exe then the utility will look for and try to run xyz.bat. If a BAT file with the same name can't be found, proxy will just fail silently.

By making copies of proxy.exe with different names and creating multiple BAT files you can run as many "hidden" BAT files as you need, neatly sidestepping the Flash limitation on passing parameters to external applications.

Here are step by step instructions to use the proxy utility to open a PDF file without the ugly DOS box.

Create a BAT file called file1.bat that contains just the following line. This is a plain text file that you can create with notepad or your favorite text editor.

start file1.pdf

Put the BAT file in a folder called fscommand along with a copy of proxy.exe.

Rename the copy of proxy.exe to file1.exe (same base name as the BAT file you created).

Place your PDF document (called file1.pdf) in the fscommand folder with the BAT and EXE files. You don't have to store the files you want to open in the fscommand folder, but for your first test this makes things easier.

Add the following command to your FLA where you want to open the PDF document (probably on a button release action).

fscommand("exec", "file1.exe");

Now put your Flash EXE and the fscommand folder on your desktop and run the Flash EXE. When the EXEC command is called your PDF document should open.

The contains the source for a simple Flash MX projector (projector.fla), a compiled version of the projector (projector.exe) and an fscommand folder with a copy of the proxy utility (renamed to test.exe), the BAT file that the proxy utility will launch (test.bat) and a PDF file (test.pdf) that will be opened when the BAT file is run. Download the example to see the proxy utility in action.

Version: 3.1
Released: March 30, 2009
Download: proxy.exe (52KB)

This utility has been around for many years now and the Standalone and Applications forum that I moderate at FlashKit is home to a few long running discussions about problems other people have encountered and how the proxy utility has helped them. Definitely worth a read.


Visit our Discussion Forums to talk about any of Northcode's tools. It's FREE to join and a great source of information for professional Flash application developers.


Hi ! Many thanks for your .exe. You saved me! I coudn't fix this fp9 projector problem with fscommand exec.

Best regards

Posted by Jerome Labarbe on 30 Aug 2007 at 11:52am

i was really frustrated untill i reach your blog, now my demo disc run perfectly thank you very mucho
Posted by Demonh8 on 5 Sep 2007 at 5:18pm
If it wasn't for people like you, we would scratch the walls with frustration whenever a company like Adobe screwed something up :)

Keep up the great work!
Posted by Peter Kalman on 10 Sep 2007 at 7:52am
You are a life saver !!!

I owe you my life. Nothing like waiting until the night before to test an extremely important part of the project. I would have paid a lot of money for that. Thank you, thank you, thank you.

"Sir here is a check with my name on it, write any amount on it and I will pay it " -Peter Griffin
Posted by Daniel Smith on 13 Sep 2007 at 11:46pm
Thanks, thanks....From me (the developer), my magazine director and all our readers.
Posted by Carlos López-Plandolit on 14 Sep 2007 at 9:24am
Maybe the only document to get over this annoying limitations.
Great instructions mate, thanx a bunch!
Posted by Seyfi Cem Baskýn on 17 Sep 2007 at 5:17am
What do you want ?, just name it. You saved my bacon on a very important job I have been struggling with. Thank You.
Posted by Andrew Keet on 17 Sep 2007 at 2:30pm
Agreed. This is an awesome script you have compiled. This has definitely saved my hide as well in creating a hybrid CD. Thank You! does not seem enough.

... and the link to the forum has helped a lot with issues I ran into.
Posted by Amy on 18 Sep 2007 at 12:27pm
Thanx man ur job is great! long life with scripting and saving ppl ;)

Posted by Paco on 19 Sep 2007 at 4:30am
You have no idea how grateful i am... you exes really helped me with that presentation...
Thanks a lot
Posted by verdesoto on 27 Sep 2007 at 5:13pm
Posted by Tom on 4 Oct 2007 at 10:40pm
Excelente! No más problemas. Gracias amigo!
Posted by Bambino on 9 Oct 2007 at 6:26pm
Dude, i think i love u!
Posted by David on 13 Oct 2007 at 1:30am
Thanks for this awesome tutorial you ROCK
Posted by The Designer on 15 Oct 2007 at 3:34pm
super duper dooooo!!

agr8 man! you did it
Posted by Muthu on 25 Oct 2007 at 4:35am
Such an annoying problem in the first place... Thank you so much for providing a solution!
Posted by Kayvan on 25 Oct 2007 at 10:48am
HELL YES! I'd love to buy you a beer, or whatever your drink of choice. I had a CD project going out today and my external files werent working. This saved my butt!
Posted by Josh on 29 Oct 2007 at 5:03pm
I will be eternally grateful!!! THANKS!!! Salú!!
Posted by marisa on 31 Oct 2007 at 6:43pm
I´m From Brasil, and i was searching how to open pdf in .exe, then I saw: It doesn´t works in CS3!
Then I enter here and there it is!!

THANK YOU! You ROCK!You Save me!

Best Regards!!!
Posted by Beno Netto on 2 Nov 2007 at 7:42pm
you have saved my insanity!!
Posted by Kirsty on 5 Nov 2007 at 9:34am
you beauty! this has taken me all day to find!!!
Posted by Mark on 9 Nov 2007 at 9:05am
waaahhh! you're my saviour! i wanna cry with happiness!! thanx a lot!!
Posted by noahvearn on 11 Nov 2007 at 9:33pm
thanks man. all the people who wrote before me are right... many, many, THHHHHAAAAAAAAAANNNNNNNNKKKKKKKKSSSSSSSSSS!!!!
Posted by Manuel on 12 Nov 2007 at 4:24pm
Thank you so much, this saved my bacon big time.
Posted by Angus on 13 Nov 2007 at 7:25am
I love you as much as a heterosexual man can love another man.

Posted by Noah on 14 Nov 2007 at 12:27pm
You are amazing!!!
Posted by Richard Freudenfeld on 19 Nov 2007 at 11:48am
You bailed me out on this one. Was beating my head against the wall so long that when it actually worked -- and so well -- I was amazed.
Posted by Calhoon on 21 Nov 2007 at 4:21pm


Posted by Fawn (from Thailand) on 1 Dec 2007 at 12:39pm
excellent .....thanks for

thank a lot...!
Posted by samir panchal on 8 Dec 2007 at 6:06am
Today is my deadline, and finally I find your blog with this GLORIOUS PROXY!!!! You just save my life.
Posted by JuanM on 19 Dec 2007 at 6:59am
I cant thank you enough. The script works a treat and gets round the annoying problem of CS3 projectors not opening bat files properly.
Posted by David Jenkins on 1 Jan 2008 at 10:26am
Like everyone else on here...i would like to express my thanks for your help and solution...
Posted by Owen Hardy on 16 Jan 2008 at 10:57am
The 737th Training Support Squadron of the United States Air Force thanks you. All of the Visual Presentations used in the USAF Basic Training Acedimic classes are built and delivered via Flash Projector Files. These files are accessed through a Master Menu (also a Flash Projector file).

Most of the lessons incorporate video utlizing the media component, and when we moved to CS3, none of our videos would launch "if" the Lesson Presentation projector file was launched from the Main Menu projector file.

We do updates continually making this a serious problem, and Adobe essentially tried to tell us it was our fault.

So thank you very much.
Posted by Dave Terry on 16 Jan 2008 at 2:49pm
I just created my first CD-ROM based presentation with a Flash based EXE homepage that links to PDFs and Word docs. I was not aware of the getURL issue because the links worked fine on my PC. But when the client reviewed the project, they recieved all kinds of IE "Security Warning" messages because, as you know, the PDFs opened within IE and not the actual application and not to mention that the browser opened behind the projector file. I came across your wonderful "Proxy" solution in a Flashkit forum after 3 days of just trying to figure-out an ActionScript solution. Needless to say, that was hopeless.

So here I am, very relieved and happy. More importantly the client is happy and I can't thank you enough. THANK YOU, THANK YOU, THANK YOU!


Posted by Will Cruz on 25 Jan 2008 at 1:57pm
Thank you so much!
Posted by Valdemar De Matos on 1 Feb 2008 at 5:18am
Thanks! I am so glad this is here, becuase I scoured the web looking for a solution. I thought it was something I was doing wrong, nope just Adobe.
Posted by Jen Z on 5 Feb 2008 at 10:39pm
Thank you! This has saved my project from the grave!
Posted by Chris Burden on 6 Feb 2008 at 6:38pm
5 AM GMT +1, four hours of searching and finally i got it. THANK YOU. omg i can finally go sleep..
Posted by Jose Francisco De la Rua on 6 Feb 2008 at 11:06pm
THX A LOT !!! - Really Usefull
Posted by Tommy on 14 Feb 2008 at 4:06pm
It's so rare to find a Flash fix that works instantly, well done. Clear, concise instructions, and a perfect workaround.
Posted by Kim on 3 Mar 2008 at 5:39am
Thank you! This tutorial really very useful.
Posted by Amol on 4 Mar 2008 at 4:09am
dude! you're awesome!!
Posted by tina on 4 Mar 2008 at 12:15pm
thank you! your tutorial save me !
Posted by yuhei on 5 Mar 2008 at 6:49am
Many thanks! After hours of googling finally someone who explained, what the problem is (WAS!) and then also the solution!!! You're awesome, man!
Posted by chris on 6 Mar 2008 at 8:57am
It's working great ... thanks a lot!
Posted by Vince on 20 Mar 2008 at 10:52am
Excellent, thank’s from Costa Rica!!!
Posted by Cristian on 27 Mar 2008 at 11:56am


print("Thank you!!!");
Posted by MilanGM on 28 Mar 2008 at 10:22am
You saved my butt. Thanks a million!
Posted by Joe W on 2 Apr 2008 at 1:27am
thanks a lot! you solved my problem, thanks to people like you that dedicate a time to help when companies just leave us in the darkness. If wasn't for your article I could of been spending weeks trying to find out why it is not working, probably would end reinstalling version 4 or something, but your solution is much better, looks more professional!
Posted by abk on 3 Apr 2008 at 3:18pm
U saved my life :) Thank You !!!!!!!!!!!!!!!!!!!!!!!
Posted by DVDavy on 6 Apr 2008 at 8:39am
Eternal thanks, man! That's really awesome!!!
Posted by Michal Kuba on 13 Apr 2008 at 3:47pm
You have no idea of the struggle i had trying to open external video files with fscommand!!!!

You're a genius, thank's
Posted by Julian Perez on 14 Apr 2008 at 3:37pm
Excellent solution, you saved my live today!!
Posted by Maciek W on 22 Apr 2008 at 10:06am
thankyou soooo much
Posted by dave on 29 Apr 2008 at 8:15am
ThankS! You have saved my project!

Posted by Stankiewicz on 1 May 2008 at 8:08am
Posted by mario on 2 May 2008 at 10:34am
Posted by TJ on 4 May 2008 at 1:08pm
Thanks for the updated tool. works like a champ.

You are KING!

Posted by BD72 on 9 May 2008 at 10:42am
thank you very much for your help!
Posted by pereda on 9 May 2008 at 7:39pm
Save my project
Posted by radu on 14 May 2008 at 3:55am
Posted by ravindar on 15 May 2008 at 10:53am
Here in South Africa, in 2010, we will have a soccer world cup. I hereby offer you a free accommodation with electricity and water included.

Ndiyabulela kakhulu mhlekazi wam!!!!
Posted by Fezile Mlungu on 16 May 2008 at 9:07am
u da man
Posted by cup on 21 May 2008 at 2:59am
Just need to put another drop in the bucket. You really saved my project. (Deadline was tomorrow and I had NO idea that CS3/Flash9 was going to do this to me)
Posted by Fen on 25 May 2008 at 3:58pm
Another message of eternal gratitude!
Adobe should pay you every time someone comes across this problem and discovers your page!
Many many thanks.
Posted by grateful on 29 May 2008 at 6:15pm
Wow, it's amazing. You're really helping me out from this nightmare. Thank you so much!
Posted by madif on 30 May 2008 at 8:25pm
I'm a beginner in flash but i'm a programmer and i always wanted to start a process from flash using fscommand, but it wasn't that you've made this possible i thank you very much both for educating me and making me more interested in learning flash.

Posted by Mohsen on 1 Jun 2008 at 3:22am
this is really great...
Now I can make the CD structure as I want...
with the use of .bat .... the whole thing has become very flexible..

Thanks for the help...
Posted by Pratik on 2 Jun 2008 at 10:02am
This is really greaaaaaaaaat
Posted by Abdullah on 4 Jun 2008 at 2:27pm
The Answer To Life Universe And mean...proxy.exe!
Posted by daniel on 5 Jun 2008 at 7:22am
I'll have to say, you solution works even better than expected. I was using another solution that opened PDFs just fine but when it came to opening video files, it just couldn't handle it (I think a Windows Media update had something to do with that). What's even better, the videos come up instantly versus the 3-5 second delay I was seeing. Thank you so much.
Posted by Dave Ramsey on 21 Jul 2008 at 9:51am

youre awesome dude!

btw the proxy.exe is not a harmful program right? :D :D :D
Posted by hadi on 22 Jul 2008 at 2:20am
If you got your copy of proxy from our site, it's safe and does only what the documentation says it does.
Posted by Tim on 22 Jul 2008 at 2:26am
Great Script. It saved my day.
Posted by Creationpool - Flash Agentur Berlin on 28 Jul 2008 at 7:40pm
AWEEEESOME man, you saved me today, i was fighting a deadline trying to run my c# application from flash, my application crashed on startup with ArgumentException not handled!

Thanks again. :)
Posted by eddiE on 30 Jul 2008 at 9:04am
Thaaaaaaaaaaaaaaaaaaaanx man alot

you give us a good help with this

Posted by Ala on 31 Jul 2008 at 6:13am
Is the source code available for proxy.exe? We have a project where the client wants to see the command window while the batch file is running.
Posted by Brian on 31 Jul 2008 at 3:48pm
Normally I would have said "just call the BAT file directly", but the issue with CS3 not calling BAT files properly takes that option off the table. The source for proxy is not available, but I just emailed you a custom version of proxy that does what you need.
Posted by Tim on 31 Jul 2008 at 4:26pm
hatur nuhun
-thanx in sundanesse-
Posted by wdy on 7 Aug 2008 at 1:28pm
What if I only need to open a folder, not a file...?
Posted by edger on 12 Aug 2008 at 5:55pm
You can call explorer.exe in the BAT file to open the folder you want. For example

explorer.exe "c:\documents and settings"
Posted by tim on 12 Aug 2008 at 6:10pm
Thank you so much it works really well!
Posted by Stephan Stroh on 19 Aug 2008 at 8:09am
Hi, I'm not sure if this is even possible... here goes:

I have two .exe files that I want to open. One is the French version and one is the English version of the same player (.exe) file.

I would like to have two buttons in my main projector file, one to open the French .exe and one to open the English .exe.

Is there a way to do this?
Posted by Mary on 19 Aug 2008 at 12:21pm
Sure, you can use System.capabilities.language to find out what language the system is running and choose the EXE you want automatically OR you can just hard code the EXEC command for each button to call opene.exe and openf.exe (or whatever you want to call them)
Posted by Tim on 19 Aug 2008 at 12:56pm
This works for me to launch a pdf in Win2k/XP/Vista. However, it is *not* working for me to launch a .exe file in Vista. I am using Flash CS3.
Posted by Chris on 19 Aug 2008 at 4:42pm
What is the name of the EXE file you are trying to launch? Does the EXE have a "shield" on the icon?

Vista makes some assumptions about what you're trying to do based on the name of the EXE. If you have the "setup", "install" (or a few others) in the file name, Vista thinks those apps should have admin rights and when you try to launch them as a normal user they will fail. The shield on the icon is the clue that Vista thinks the application might need more rights

You could also be running into the problem using the start command in Vista that I describe in this post: Fixing the Windows Start Command in Vista.
Posted by Tim on 19 Aug 2008 at 5:42pm
Great job! Will it work for opering .app-files on mac also? Guess I'll just have to try...brb
Posted by David on 21 Aug 2008 at 11:26am
Crap. It won't work for mac. Any ideas for a solution there? Thanks
Posted by David on 21 Aug 2008 at 11:53am
I know the problem exists on the Mac too, but I'm not sure if it's the same problem or not. I haven't put a lot of work into investigating that side. I've been getting a few requests though, so I might have to do something soon.
Posted by Tim on 21 Aug 2008 at 12:26pm
thanks very much man
it's me pleasant to be one of your fans
thanks a lot
Posted by creativity lover on 27 Aug 2008 at 10:56am
THANK YOU!! Like all the previous comments, you have saved me sooooo much time, frustration and not to mention my job too!! . . . My project is finally finished!!!

THANK YOU again!
Posted by Raphaelle Wilson on 27 Aug 2008 at 11:34pm
Posted by paul on 2 Sep 2008 at 7:05am
Pulled me out of a hole - thanks very much indeed. Works brilliantly.
Posted by Will Burrows on 8 Sep 2008 at 5:14am
Brilliant. Thank you very very much!
Posted by Omar on 14 Sep 2008 at 9:52pm

Nice stuff...very useful.
Posted by jasvinder singh on 16 Sep 2008 at 10:24am
Thanks a lot. You are GOD.
Posted by flasherKEN on 18 Sep 2008 at 2:44am
you can place your desktop shortcuts in the folder and call them with the .LNK extension......

Exactly what i was looking for.
Im making a flash program that runs apps instead of having loads of shortcuts on my desktop i can have them in a nice flash prog.

Just like a sidebar in vista but with your own design..

Posted by Hyp3r on 20 Sep 2008 at 5:49pm
thanks, thanks thansk thanks,thanks so much!!!!!! My heart beats again!!!
Posted by Ruben on 23 Sep 2008 at 4:42am
hey super!

thanks a lot !!!!!! that's really a tutorial - should be on first place when googling for fscommand/exec

Thank You.
Posted by genesis-upanishad on 23 Sep 2008 at 5:03pm

I and my brother work about one week in a Multimedia CD project. when it was in end we knew that The .EXE of project can't open files that was in "fscommand" folder!!!!!!!!! in a shame error!!

this was end of interesting when i found Your blog...
thank you so much and if i can help you please welcome to me.

Best Regards

Reza Amya & Saeid Amya
Brothers Design
Posted by Reza Amya on 25 Sep 2008 at 9:06am
Thank you so very much, I can sleep tonight... God bless you...
Posted by Heidi on 27 Sep 2008 at 7:13am
This thing with fscommand and Vista was driving me crazy today. Thanks to this post all is ok now and IT WORKS! I'm very grateful. Thank you :)
Posted by zamrai on 2 Oct 2008 at 3:28pm
I am creating a CD rom.
I have created a flash.exe file with fscommand folder inside there's a .bat file + .exe file + .pdf all have the same file name.
Problem the file name is called:
ICS telecom v9 - install instructions.pdf and it cannot be name changed note there is spaces between characters and a hyphen whichdoes not work. Can I create a variable for that file name as in the future the file name will change ie not v9 but v10 I am not sure what to do next, please help...thanks
Posted by sandra wilson on 8 Oct 2008 at 9:36am
You can call the bat file and the exe file anything you like. Choose something simple without spaces or special characters. Inside the BAT file you can call the PDF by it's real name, and use quotes around the filename if you have to. You just have to remember what EXE file to call in your FLA to open the right PDF file.
Posted by Tim on 9 Oct 2008 at 2:13pm
hi, i have this shameful error !!!

very so much thank you, GOD FLASH MAN !
Posted by saiednt on 13 Oct 2008 at 9:42pm
You've just helped another fella out of a sticky situation - how generous of you to share this with everyone - did the whole copy2/proxy.exe trick - worked a treat - thankyou!!!!!!!!
Posted by Ian on 31 Oct 2008 at 12:11pm
mr. google has brought me 2 this incredible post and one of my worst problems has finally disappeared! thank you for sharing this with the whole flash community.
Posted by vinicius on 7 Nov 2008 at 2:54pm
This is incredibly useful information! Thank you!
Posted by Rowan on 10 Nov 2008 at 5:36am
Hey Man,
You are a ture life saver... I LOVE YOU!
Posted by Ammar on 12 Nov 2008 at 7:10am
Thanks so much for helping me meet my deadline of this afternoon! Fixed my problem in no time!
Posted by Andrea on 21 Nov 2008 at 7:38am
You just saved me from a serious headache !,I dont care much about the proxy.exe file .. but lunching from the bat is a life saver!
Posted by Raymond on 25 Nov 2008 at 11:57am

Honestly, I can't thank you enough.

I love you. Like, properly. For keeps.

Posted by Dan on 26 Nov 2008 at 9:54am
excellent bro....
thanx 4 everything.....
u brought a new life 4 me...

two thumbs up
Posted by noname on 1 Dec 2008 at 11:40pm
You're a clear example how one smart man can KILL a huge, stupid, arrogant, smelly, full of shite beast called ADOBE.

How can I send a beer over your way?

Posted by Jebac on 4 Dec 2008 at 2:28am
No other words to express my happyness.... [:)]
Posted by Satosh Kumar on 17 Dec 2008 at 5:09am
Thanks SOOO much!
You're a life saver.
Posted by MisterJom on 1 Jan 2009 at 1:53am
Hi, Thanks for proxy.exe, but i want to open different PDF from different butons. so its abel to only open one pdf. PLEASE Guide me.

Posted by Neelesh Upadhyay on 2 Jan 2009 at 12:09am
Just make copies of the EXE and BAT file, one for each PDF you want to open.
Posted by Tim on 2 Jan 2009 at 12:43am
i loooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooove you ,you saved me , mille thanks
Posted by amira on 3 Jan 2009 at 4:23am
This is coooooooooooooool
you're the best tim
Posted by Ahmed elshrkawey on 14 Jan 2009 at 5:08am
Posted by laranjinha on 15 Jan 2009 at 8:32am
Woooow... it's awesome, work like a charm!! You're really great, u know.. Been searching everywhere to solve that problem, till i found your tool. Really great.. Thank u so much, bro..
Posted by Eddy Surahman on 9 Jan 2009 at 10:26pm
Wooow you are the man!
Thank you very much
Posted by Andres on 22 Jan 2009 at 4:41pm
after wasting over a day, you have helped me sort this out.
u r a legend ;)

why on earth has adobe not sorted this out!?!?

Posted by Greg cook on 27 Jan 2009 at 4:45am
man, your proxy is ******* amazing stuff for my project!
thanks from russian guy

Posted by chunya on 29 Jan 2009 at 9:46am
Thanks! This worked great for opening my PDFs from Flash. I was wondering if this would work to open up a windows explorer window as well. If so, what would those steps be?
Posted by Beth on 9 Feb 2009 at 12:17pm
Sure, just put something like this in your BAT file...

explorer c:\

The "explorer.exe" is not Internet Exporer but the Windows Explorer and if you google around you'll find it has a slew of command line options you can use.
Posted by Tim on 9 Feb 2009 at 1:20pm
Awesome script!
My projector is fullscreen by default but after opening the pdf it goes to normal 100% view. Any way of keeping it fullscreen, PLUS making the pdf appear in focus over the top of the Flash projector???
Posted by Dave on 16 Feb 2009 at 1:14am
That's another issue you can read about in this post: Problem with Fullscreen Flash Projectors
Posted by Tim on 16 Feb 2009 at 2:06am
hey tim you = awesome i just scrolled through and read how many people you helped with your work ..

do you have a link or update on how to use a simlar solution on a mac.

im on a quest right now to find the answer if i do ill post back here.

either way muchas gracias knowing how to do this on windows helps out a lot!

thank you thank you
Posted by sergio on 20 Feb 2009 at 1:17am
Posted by Alexis on 20 Feb 2009 at 2:54pm
Thanks so much definetly a life saver! My client was busting my ass and I still was trying to do the fscommand EXEC trick which wasn't working anymore. Thank you so much for the exe :)
Posted by Fahim Akhter on 23 Feb 2009 at 8:10am
hi, i try it on mac and it didn't work. any solutions for that ?
Posted by amirul on 1 Mar 2009 at 10:23pm
It's a Windows only solution, I don't have anything similar for the Mac. Sorry.
Posted by tim on 1 Mar 2009 at 11:26pm
from the morning I was trying to overcome this problem. the only and final solution is from you. thank you man it is a great job.
Posted by ali on 7 Mar 2009 at 9:36am
you're the best! I can't believe that there is a way to do this for free. I was about to invest in a $300 program. This change everything. Thanks, you're a saint, bro!

Posted by rod on 14 Mar 2009 at 3:14pm
I make one of those "$300 programs" but it's overkill if all you're doing is launching BAT files so FREE is about the right price for that :)
Posted by tim on 14 Mar 2009 at 3:48pm
Thanks a million, Been trying for ages to get that black screen that comes with using .bat files off.

You're a life saver. Ring me whenever you're in Nigeria. I'll get you a chieftaincy title.
Posted by demola on 15 Mar 2009 at 2:49pm
Thank you man, I have been searching for something like this for long time. Such an irritating thing solved in no time. Works perfect!
Posted by kele on 27 Mar 2009 at 10:09pm
Awesome!! Wonderful tool!

Question: I have a .bat file that calls another .bat file. The first file passes arguments to the second file. I would like to use proxy.exe to keep the dreaded black box from popping up on both files. However, it doesn't appear that I can achieve this since I need to pass arguments from .bat file to the other. Is this a correct assumption?

Thank you!
Posted by mmcneill on 30 Mar 2009 at 4:43pm
I just modified the proxy tool to pass whatever command line arguments it gets to the BAT file. The version of proxy.exe with that change is 3.1. I just uploaded it to the blog and I sent you a copy by email.
Posted by Tim on 30 Mar 2009 at 5:03pm
thank you make me happy realy...iiiiiii love you hhhhhhhhh:-)
Posted by moad on 3 Apr 2009 at 12:56am
Hello and thank you so much for this tutorial. It really helped me a lot on my work. Like many had said before me, i try using fs execute in Flash and it never work until i saw this.

I try using in Window XP and it works like a charm. But when i brought this to Vista. It couldn't execute. So what could be the problem? I'm using Adobe Flash CS 4 but i continue to save the file in CS3 and execute the Projection file as Flash Player 9.

Please advise....
Posted by Sapphire on 8 Apr 2009 at 12:23am
What is the name of the EXE file you are trying to launch? Does the EXE have a "shield" on the icon?

Vista makes some assumptions about what you're trying to do based on the name of the EXE. If you have the "setup", "install" (or a few others) in the file name, Vista thinks those apps should have admin rights and when you try to launch them as a normal user they will fail. The shield on the icon is the clue that Vista thinks the application might need more rights.

You could also be running into the problem using the start command in Vista that I describe in this post: Fixing the Windows Start Command in Vista.
Posted by Tim on 8 Apr 2009 at 1:36am
WOW! now I don't have to do all our Autorun cd's with MultiMedia Builder, Flash just looks better.

Thanx a Stack!
Posted by Mariaan on 13 Apr 2009 at 10:48am
Thanks a lot!

I thought I was doing something wrong with the code. :)
Posted by oconel on 20 Apr 2009 at 7:04am
Hey man thanks a lot this works perfect but i Have
a little problem it works perfectly with .exe files
but it doesn't work with .msi Setup packages
so do you have any ideas to work this out.
Posted by Adeli on 21 Apr 2009 at 11:41am
I'm gonna need a few more details about how it "doesn't work". I've sent you an email :)
Posted by Tim on 21 Apr 2009 at 2:28pm
That REALY help to solve one more Vista issue....

Posted by Gabriel Melo on 22 Apr 2009 at 9:22am
Hi! I'm from Croatia and this is a thing I've been looking for for months... This is GREAT STUFF! I can't thank you enough...
Posted by Alex on 23 Apr 2009 at 6:00pm
This works perfectly for me except excel files on XP machines. Why does it work on Vista but not XP and can you help?
Posted by Michael on 24 Apr 2009 at 3:41pm
Sure, what are you trying to do?
Posted by Tim on 24 Apr 2009 at 5:36pm
It is really great. Can it modified to run in vista without admin permission.
Posted by Clerison on 25 Apr 2009 at 11:59am
You don't need admin permissions to make proxy work on Vista, unless what you're doing requires admin permissions, like running an installer or setup program.
Posted by Tim on 25 Apr 2009 at 1:03pm
THANK YOU TIM............... Thank you
Posted by Isam M. Wali on 26 Apr 2009 at 7:46am
Thank you very much!
Posted by Abel B. on 28 Apr 2009 at 4:31pm
Thanks Tim, this was a great help.
Posted by Uiliam Cruz on 2 May 2009 at 5:45pm
Posted by EvilBeaver on 3 May 2009 at 10:03am
Thanks a lot !!!
As with many others' you helped me a lot.

I had a question about weather you can pass arguments
to the .bat file or if you can just call it ?
Posted by Boris on 6 May 2009 at 5:38pm
You can just call it. You haven't been able to pass arguments with EXEC since Flash MX was release.
Posted by Tim on 6 May 2009 at 6:13pm
Just one phrase: You Rock!
Posted by Manuel on 7 May 2009 at 12:22am
This method was a lot of help on my last project. Could this work for opening swf files from a windows projector as well? I got it working outside of flash (just double clicking the bat file and it opens the swf). But I can't seem to get it to work from within my flash projector.
Posted by Beth on 7 May 2009 at 1:57pm
The proxy tool was designed to be called from a Flash projector. The example in the ZIP file shows how to call it from a Flash projector. The easiest way is to put the BAT file, the renamed proxy.exe file and the file you want to open in the FSCommand folder. Check out the example!
Posted by Tim on 7 May 2009 at 2:13pm
hey, I'd like to know how to make a .bat file to trigger .exe from another folder
(which exists with the .bat file ) thanks,
Posted by ali on 12 May 2009 at 3:59am
You can execute any EXE file by putting it's name on a line by itself in the BAT file. If th EXE file is not in the same folder, include the path (relative or absolute) to where the EXE is located.
Posted by Tim on 12 May 2009 at 4:30am
Thanks a lot for your proxy.exe. I got rid of my great problems that i was facing. Now I can prepare a good CD presentation to distribute our software.
Posted by Arun on 13 May 2009 at 6:35am
GRACIAS hombre este es el único que funciono!!!

Posted by Santos on 13 May 2009 at 6:39am
Hi Tim,

I tried to do exactly the same thing, launching a pdf file from a flash projector via the fscommand mechanism. I wrote a small executable (VC++) that opens the pdf.

From the flash projector it takes up to 10 seconds until the pdf appears (which is unacceptable), but if I start the exe directly it works instantaneously.
So I googled around and hit your website with the nice proxy application that does the same. Unfortunately I cannot use your tool because my application is for company-wide distribution and the IT guys won't let me distribute software without having the source code from which they know it doesn't anything bad.

So can you give me a hint what might be causing the delay? I tried ShellExecute, the system("...") call, CreateProcess, always the same.

Thanks very much...
Posted by Gizmo on 15 May 2009 at 7:19am
Hi Gizmo :)

The proxy application is being used by thousands of people all over the world and it's been shipped as part of large commercial CD distributions. The code doesn't do anything malicious, it just opens files. We've signed the application too so that you know you have a clean copy. That said, I know how the "IT guys" can be with their networks :)

Proxy uses CreateProcess to run the BAT file and doesn't really do anything special except fix up the command line it's passed to resolve the UNC path. If you want to show me the CreateProcess call you're using I'll have a look at it for you.
Posted by Tim on 15 May 2009 at 7:46am
Hi Tim,
the CreateProcess call doesn't really work because of the pain-in-the-a-UNC path problem. Says cannot find the file.
I just called it like this:
CreateProcess(appName, NULL, NULL, NULL, FALSE, HIGH_PRIORITY_CLASS, NULL, NULL, &si, &pi), where appName is the batch file, si and pi are startup and process information structs.
ShellExecute and system are cause the delay I mentioned above.

Thanks for your help, you can also reply by email if you prefer.

Posted by Gizmo on 16 May 2009 at 5:23am
Leave the lpApplicationName NULL and use the lpCommandLine instead. This also allows you to tell CreateProcess to run a BAT file using CMD.EXE (or, depending on which OS you're using). When you use the lpApplicationName, Windows assumes this might be a partial file name and tries to complete it for you, which may explain why you're seeing a delay there. Not sure why that would happen with ShellExecute though. I'm going to send you some code from proxy so you can see how I'm doing it. Hopefully that will help!
Posted by Tim on 16 May 2009 at 5:43am
Thanks! This explained it all very well!
Posted by Nathan on 21 May 2009 at 11:09am
Yeah, thanks very much Tim, I think I'll get along now.

Best, Gizmo
Posted by Gizmo on 22 May 2009 at 5:25pm
This question may be off topic a bit, but if anyone knows the answer I thought it would be you. I have a data dvd with a flash menu that opens pdfs using bat files and the proxy file. I wrote the bat files with a path to the D drive where all the files are located on the dvd and it works great. Problem is, not all of the users of this disc have the D drive assigned as their DVD drive. Do you know if there is a way to use this method with out it mattering which drive letter that the user's DVD is assigned to?

Thanks for all your help!
Posted by BethVanVel on 26 May 2009 at 9:56am
You can find the drive letter where your EXE was started from by examining the _url variable (in AS2) like this:

drv = _url.substr(8,1);

From that you can form a path to any folder on the CD/DVD since they won't be changing after you publish.
Posted by Tim on 26 May 2009 at 10:43am
bro it works awesomely perfect on my pc but when i write a cd then it stop working what am i suppose to do now :( plz help deadlines to meet or i will be dead
Posted by shakil on 27 May 2009 at 4:11am
Have you got a hard coded path in your BAT files or in your FLA that would make it work only on your machine?
Posted by Tim on 27 May 2009 at 4:30am
MERCI BEAUCOUP (Thks you very much)

I love you
Posted by atinao on 28 May 2009 at 5:39am

I have 14700 PDF files. And if I should make 1 EXE for each PDF, then total size of EXE files becomes around 800 MB!

Is there another way to do this? Any suggestions? Can same EXE file be used for every PDF and BAT files??

Posted by Sinan on 1 Jun 2009 at 3:11am
You can't use one EXE file for everything because you can't pass parameters from Flash via the EXEC command. The only solution that doesn't involve creating one helper file per document that you want to open is a third party swf2exe utility like SWF Studio.
Posted by Tim on 1 Jun 2009 at 4:13am
1,000,000,000,000 thank yous!!!!

5 years ago i suffered to find the bat solution for a project i did for a client. Now the problem came back again.. but here are you to save me ;-)

Posted by Nacho on 5 Jun 2009 at 2:33am
Thanks a lot, Tim! Very useful stuff
Posted by kirill on 10 Jun 2009 at 11:52pm
gracias viejo, te pasaste...
un solucion buena y practica

Thanks a lot!!!

Posted by Claudio on 17 Jun 2009 at 3:09pm
You are an oasis in the middle of the fscommand information desert, Thank you very mutch, you are the men!!
Posted by Nuno on 18 Jun 2009 at 10:17am
thank youuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuu.

My boss is very content of me
Posted by lobna on 23 Jun 2009 at 9:52am
I am trying to do this exact thing. Open a PDF from a flash projector (for Promotional CD) I am using AS3 and seem to have run in to a really REALLY big brick wall. I can open the pdf in a browser but this is far from ideal as it opens behind the projector so user has no idea if the button has worked. Is there anyway of executing a pdf in Adobe Reader using AS3? Can this method be adapted to AS3? Unfortunately I just don't know enough about it to figure it out myself :(
Posted by Emiloly on 30 Jun 2009 at 10:16pm
Oh duh!! It does work with as3 :D Please disregard all my last nonsense! PS Thank you so much for this!!!
Posted by Emiloly on 30 Jun 2009 at 11:40pm
Dude, I love you!!!!
I'm from Brasil and you saved my life!!!

Many thanks!
Posted by Guilherme Ioppe on 5 Jul 2009 at 12:54pm
Un millon de gracias! After 2 days of searching and viewing all kind of posts I found you site, thanks from mexico!
Posted by Gaby on 8 Jul 2009 at 2:18am
thanx for this post i solve my problem :)
Posted by lav on 10 Jul 2009 at 5:22am
You are the second coolest man in the world. Many thanks. Now if you would only work on the Mac side.
Posted by Camilo on 14 Jul 2009 at 11:27am
eres de lo mejor

you r great!!!!! thanks TIM!!!!!
Posted by david on 16 Jul 2009 at 11:41pm
Many many thanks,
I searched long and hard to a solution and yours works perfectly.

Great job!

Posted by Yuval on 2 Aug 2009 at 7:35am
Man! You have no idea how lost I was untill I found your blog. You are going to heaven for sharing such a solution for free.


Posted by glaucia on 4 Aug 2009 at 5:51pm
free source?
Posted by santiagok on 12 Aug 2009 at 12:14pm
wow man! I'm really really happy cuz I found your blog and this explanation! *-* Congrats you're the best!! thanks!
Posted by @nessalatini on 19 Aug 2009 at 4:12pm
You don't have idea how much time i had lost figuring a way to do this, thank you so so so so much. Best regards from México!!!
Posted by Francisco Ortiz on 21 Aug 2009 at 12:32pm
Thanks a lot! =)
Posted by Felipe on 21 Aug 2009 at 11:37pm
ok, here's my story
I'm trying to make a flash presentation that opens a folder when I click a button, after I finished the presentation I discovered that there is no action script command to open folders directly so I decided to write a autoit prog that will open the folder when flash calls it instead. I then discovered that fscommand doesn't work, so I searched a little while until I found this page so I downloaded proxy.exe.
Now I have the flash projector opening proxy.exe, which opens proxy.bat, which opens file.exe, which opens the folder.

Posted by George on 4 Sep 2009 at 11:04pm
There's no reason I can think of why this wouldn't work. I'm going to send you a quick email to see what you've done George. Stay tuned...
Posted by Tim on 4 Sep 2009 at 11:06pm
All my love!!!
I've been trying sooo many days.
Thank you!!!
Posted by Katerina on 6 Sep 2009 at 7:07pm
It works now, great workaround.
Posted by George on 10 Sep 2009 at 6:42pm
i make some changes in the file and run it in swf format but my batch did did not response may i know why thank you so much
Posted by eba on 16 Sep 2009 at 5:04am
The EXEC command won't work from a SWF, only from an EXE file.
Posted by Tim on 16 Sep 2009 at 5:23am
thanku for the proxy.exe it helped in my current project. i have a query -- i need to change in batch file to access a exe file in a previous folder.
Posted by pushpalatha.l on 18 Sep 2009 at 11:56am
I came across proxy.exe yesterday and managed to get my projector working last night, opening pdf files. Brilliant!
Unfortunately, it doesn't work on my Vista computer at work (home XP). I haven't made any changes to the file and it worked last thing at home but not first thing at work this morning. Is this something to do with Vista?
Posted by Marion MacDonald on 30 Sep 2009 at 9:49am
I left you a comment the other day asking if XP/Vista was the reason for a problem I was experiencing. It wasn't (blush) - it turned out that I had not copied all files from one laptop to another - more hurry less speed.
Proxy works well and I am very grateful.
Posted by Marion MacDonald on 1 Oct 2009 at 4:44am
Thank you! That's a pretty clever solution :P I was going to make an executable that directly opened a pdf, but i hadn't thought about the exe using its own file name to look for the correct file to open. Again thank you very much, you saved me a lot of trouble! :D
Posted by Ricardo on 29 Sep 2009 at 1:29pm

There is a problem with opening excell (xls) files from flash8 projector. Actually, everything works perfect on my machines, but the client can't open the xls files. I created the presentation in Flash 8 and used your proxy file to hide ugly cmd window. When he tries to manually open the *.exe file from a fscommand folder, he gets a security warning: 'The publisher could not be verified'. When he hits 'Run' nothing happens either.
If you have an idea how to solve this issue, please let me know.

Thank you very much
Posted by Darko on 30 Sep 2009 at 5:05am
That's standard behavior for a Windows application when downloading an unsigned application from the internet. If you buy a code signing certificate and sign your application you'll still see the warning dialog, but the publisher name will not be "unknown".

You can read about code signing at Introduction to Code Signing. You can also get rid of that message by copying the file to a FAT32 file system and then back to an NTFS file system. That removes the flag that tells Windows that the EXE file was downloaded from the internet.

If the security issue isn't the reason that your users can't open XLS file, make sure they have Excel or the Excel Viewer installed.
Posted by Tim on 30 Sep 2009 at 6:03am
hi, thanx for solution, but i already open pdf files with geturl in flash cs3. it works fine. i need to run an exe now , what should i do?
Posted by roshan on 19 Oct 2009 at 10:10am
You can use proxy.exe to launch a BAT file with anything in it. So instead of putting commands to launch a PDF file, just launch your EXE from the BAT file. If you can put the EXE in the fscommand folder then you don't even need the proxy utility (unless your EXE is one that can't be launched from Flash).
Posted by Tim on 19 Oct 2009 at 11:10am
Thanx, when we open a pdf through geturl, it comes whithin an i.e window, but proxy opens acrobat directly. but when i use Swf studio, the proxy doesnt work, what should i do to open acrobat reader directly with swf studio? and how can i open an exe file outside fscommand folder with swf studio?
Posted by Roshan on 21 Oct 2009 at 3:59am
You don't need to use the proxy utility with SWF Studio, you can use the Shell.invoke or commands to open the PDF files directly in Acrobat (or the application associated with PDF files). To open an EXE file from SWF Studio you can use the Shell.execute command. The best place for questions about SWF Studio is in our community support forums.
Posted by Tim on 21 Oct 2009 at 4:50am
Thanks for creating proxy! It did exactly what we needed.
Posted by carmine on 21 Oct 2009 at 4:48pm
Posted by Deepak on 24 Oct 2009 at 12:14am
Thank you so much for your solution, you saved my life too !
Posted by J2M on 1 Nov 2009 at 12:47pm
I am sorry, but I cannot seem to get this to work! (I feel like a ra-tard) I have created a new flash file and placed a button on the stage in the same folder I created a directory called "fscommand" and placed test1.bat and test1.exe(proxy) inside it. I can manually run proxy and it opens my program but when I try through my .swf it does nothing at all. Here is the code....

fscommand("exec", "test1.exe");
Thank you in advance!
Posted by Phaytal on 4 Nov 2009 at 8:00pm
Without seeing what's in the BAT file (but assuming that it works) my best guess is that you're just running your SWF instead of publishing it as an EXE. The EXEC command will only work from an EXE, not from a SWF (even if you double click on the SWF and run it in the standalone player).
Posted by Tim on 4 Nov 2009 at 8:53pm
Posted by Eduardo on 26 Nov 2009 at 1:29pm
great. success. many thanks
Posted by domju on 29 Nov 2009 at 11:41pm
thank you alot.....Sir!
from Indonesia with Love....!
Posted by adiarsa on 1 Dec 2009 at 1:21pm
Thank you!

If anyone needs to open a folder just type in the .bat:

explorer.exe C:\Users\johnsmith\Pictures
Posted by David on 6 Dec 2009 at 6:15am
Hi, This is fantastic.

I'm having some trouble opening a folder from a E:\ drive flash usb

I have a button in my flash projector with the following code

on (release){
fscommand ("exec", "explorer.exe")

inside the fscommand folder I have the explorer.exe and a .bat file with the following;

explorer.exe E:\documents

But it's not opening the folder. I would appreciate any hints as to where i'm going wrong etc... Thank You!!
Posted by Rob on 14 Dec 2009 at 9:59am
I'd call the BAT and EXE files something other than explorer.* to avoid conflicts with the "real" explorer.exe that you're trying to launch to open a folder. Rename a copy of proxy.exe to test.exe and call your BAT file test.bat. Call fscommand("exec", "test.exe") from Flash. Make sure your BAT file contains one line with a call to explorer.exe e:\documents and you should be good to go.
Posted by Tim on 14 Dec 2009 at 11:43am
Good job with this proxy application, it has helped me greatly in the past.

Unfortunately, I've ran into a problem this time and I can't seem to find a solution, so I thought I'd post it here.

My Flash application calls a BAT file and then closes itself. The BAT file runs another application and once that one closes down, the Flash application starts again. This works fine from a BAT file, since it automatically waits for a program to close before moving on to the next line.

The problem arises when using the proxy application as there is no waiting period and therefore the Flash application never restarts after the other application is finished.

Is there any way around this? Maybe a command I can add to the BAT file that would force the wait?

Thank you in advance!
Posted by rdoroana on 3 Jan 2010 at 7:01am
The proxy tool returns to the caller almost immediately, but unless you're calling a renamed copy of proxy.exe from your BAT file, the BAT file should be waiting until the EXE is finished. Can we move the discussion to the support forums?
Posted by Tim on 6 Jan 2010 at 12:13pm
I think all the other comments here convey my gratitude and appreciation for your valuable help.

Awesome work.
Posted by Nick on 7 Jan 2010 at 11:53am

Thanks for the great workaround! Youd think Adobe would pick up on this by now.

Is there an elegant solution for a CD with 50 pdf files to be opened? Or do I need to create 50 exe & bat files?

Can these 50 pdf files be organized in sub-folders? Or do they all have to be directly in the fscommand folder?

To make this a Mac hybrid, would you recommend using applescript for each file?
Posted by steve on 11 Jan 2010 at 11:06am
There is no elegant solution for handling multiple files, unless you use a tool like SWF Studio (Windows only). For the Mac you're going to have to do pretty much the same thing except use one AppleScript per PDF file you want to open. The PDF files can be in subfolders as long as the EXE/BAT (or AppleScript) files are all directly in the FSCommand folder so Flash can "see" them.
Posted by Tim on 11 Jan 2010 at 11:23am
Thanx a lot.

I was searching for a solution for a long time.

Now, I got it.

Thank you!
Posted by Rui on 25 Jan 2010 at 12:58pm
Posted by Grace on 2 Feb 2010 at 5:24pm
Wow! Thanks a lot for this simple but intelligent solution. This was a big savior. I was breaking my head to figure out why the damn exec command was not working. Adobe should buy this solution from you.
Posted by Cloudwhale on 12 Feb 2010 at 2:46pm
Thanks! And How many files (exe/bat) I can create? Because I understood that there is a limit. :-)
Posted by Aurora on 13 Feb 2010 at 5:21pm
There is no limit on the number of BAT files you can create or call.
Posted by Tim on 13 Feb 2010 at 6:50pm
I'd just like to say thank you SO much! You have no ideia how much you are helping me, I was looking for this information for so long... It's really nice of you sharing your intelligence with us. A flawless job!
(sorry because of my bad english..). Success!
Posted by summer on 2 Mar 2010 at 8:58pm
Thank you!!!! You saved me :)
Posted by Tyrany on 4 Apr 2010 at 2:55pm
wow.. nice job Men.. rly smooth and nice! :)
Posted by maychem on 9 Apr 2010 at 4:20am
this is just awesome :)

I can now go party because it's friday!
Posted by andrius on 9 Apr 2010 at 10:28am
thanks a lot..
Posted by Ceguhadu on 11 Apr 2010 at 2:42am
While this works well for launching apps I wanted to launch a messagebox or an error message box... a simple one at that... this option does not give me that option for some reason why is that?
Posted by Dennis on 13 Apr 2010 at 11:33pm
The proxy tool was designed for launching applications, specifically BAT files, from Flash. Message boxes are not applications or BAT files. If you could write a BAT file to display a message box then you'd be all set. If you could write your own application to display a message box then you wouldn't even need to use the proxy tool, you could just call it from Flash.
Posted by tim on 14 Apr 2010 at 12:23am
Good work, thanks!
Posted by Skeptik on 19 Apr 2010 at 3:40am
I'm trying to launch a wmv file from flash. I used your proxy.exe and it only starts media player, without playing the file. Can you please help me?
Posted by Dan on 20 Apr 2010 at 10:13am
Check out one of my other posts about fixing the Start command, I think that's what you're running into.
Posted by Tim on 20 Apr 2010 at 12:13pm
Thanks a lot. Very helpful for a project. Customer wanted PDF to open maximized, so using a bat file was the easiest option. Made it a much neater process.
Posted by Vishnu on 22 Apr 2010 at 8:06am
Man! Thanks a lot! I am able to go home early from work because of this one..... All the best! THANKS!!!!!
Posted by RJ on 28 Apr 2010 at 10:42am
Thanks a lot
Posted by Gopal on 10 May 2010 at 7:04am
Today I spent 30 mins making a flash intro to a powerpoint presentation. Then I spent ALL DAY trying to run the ppt from Flash.

THANK YOU !!!!!!!
Posted by cwir on 13 May 2010 at 12:04pm
THANKKKK YOUUUU!!! This The DAMMNNN Solution i've been looking 4!!
Posted by Bayusegara on 18 Jun 2010 at 12:59pm
"You don't have to store the files you want to open in the fscommand folder". If the setup.exe that I want to execute is inside a folder call "driver"


What is the path that should I use in my bat file located inside the fscomand?

Posted by Henry on 25 Jun 2010 at 2:38am
Since you know where the fscommand folder will be on the CD you can use an almost absolute path like \fscommand\drivers\setup.exe or you can use the %CD% environment variable (that expands to the current directory) to form an absolute path like %CD%\drivers\setup.exe or you could use a relative path .\drivers\setup.exe to locate the EXE file.
Posted by Tim on 30 Jun 2010 at 4:00pm
Thanks a lot for proxy.exe it solved my problem

thanks thanks
thanks thanks thanks
thanks thanks thanks thanks
thanks thanks thanks
thanks thanks
Posted by Gurmeet Singh on 30 Jun 2010 at 2:44pm
i was really frustrated untill i reach your blog, thank you very much :-*
Posted by ISLAM on 9 Jul 2010 at 6:05am

We still face a problem. We call a setup.exe from the fscommand, which is supposed to run a Windows installer (an .msi file). The setup.exe performs this well when called from Windows, but when invoked from Flash projector, it fails opening the MSI. Seems some user authentication problem. Any clues?
We even tried the .BAT route : still same.

Thanks in advance....
Posted by raghu on 17 Jul 2010 at 1:52am
The installer probably needs admin rights. When proxy is started it won't have that unless the app that started it also has admin rights. Applications inherit rights from their parents and they can't be upgraded unless they are started using ShellExecute instead of CreateProcess. You should be able to make your installer work if you have the BAT file use "start setup.msi", the start command should create a separate process. You'll know you got it right when you see the UAC prompt appear when your MSI installer starts.
Posted by Tim on 17 Jul 2010 at 2:59am
Great! I see the proxy.exe has a digital signature. Will you allow use it professionally? heh, we will use it anyways of course.
Posted by JJ on 17 Jul 2010 at 5:56pm
The proxy utility is absolutely FREE to use for personal or commercial projects. The digital signature is there to assure you that you have a valid, unmodified copy. If you want a copy without a signature (so you can add one of your own) for use in a commercial project, just shoot me an email.
Posted by Tim on 17 Jul 2010 at 7:23pm
Hai thaks a lot... i was fighting with flash 8 to execute a pdf file from a Flash EXE... thanks a lot for ur blog and a small doubt .. do i need to create batch files for each and every document suppose if i have more than 10 documents that i given a link for seperate buttons. do i need to create batch files for every PDF Documents...........

Kindly help me in this regards
Posted by Zeni on 24 Jul 2010 at 6:55am
Yes, you will have to create one BAT file and one EXE for each document you want to open. It's a bit of a pain, but necessary because Flash won't let us pass arguments out of the projector.
Posted by Tim on 24 Jul 2010 at 6:56am
Is there any way to get the return code from the exe and pass it back to the FLASH application?
Posted by John on 12 Aug 2010 at 4:11pm
The only way would be if the EXE created a file that Flash could load after the app finished. The problems then become (a) timing, the Flash app would have to loop and wait for the file to be created and (b) where to look for the file. The proxy tool could simplify the second problem by putting the exit code in a standard location, but then you still have to poll for the result without knowing if the app crashed or is just busy. This is where a third party projector tool, like SWF Studio can really help.
Posted by Tim on 12 Aug 2010 at 5:20pm
This solution works for opening up a pdf file however my problem is getting the pdf to open to a specific page. How do I do that?
Posted by Mark on 13 Aug 2010 at 3:59pm
Since you can't pass a parameter out using fscommand you'd have to know which page you wanted ahead of time. Once you know that you can add the /A parameter like this AcroRd32.exe /A "page=3" "c:\test.pdf".
Posted by Tim on 13 Aug 2010 at 4:06pm
You mentioned if I had SWF Studio, I wouldn't need to go through the process you outlined. I have a main EXE file with my main GUI. From here I load external swf's. I need to have several buttons throughout the modules that are loaded to open Word docs and PDF's. How would I do this using SWF Studio settings? I'm sorry, I'm a designer, not programmer and if you have responded to this same comment, I apologize. Thank you!
Posted by Brian E.W. McNulty on 24 Aug 2010 at 12:14pm
You just use the command. If your PDF file (for example) is in the same folder as your EXE then you would just say{path:"startdir://file.pdf"}); and that's it. will work with any type of file. If you can double-click on it in Windows, will launch it too!
Posted by Tim on 24 Aug 2010 at 1:13pm
Posted by J.J. on 19 Oct 2010 at 3:51pm
............... THANK YOU ............
............... THANK YOU ............
............... THANK YOU ............
Posted by Ngubek on 22 Oct 2010 at 1:31pm
Oh my good Lord, you saved my butt just in time. I worked a full month on this EXE and had to link up third-party EXE's at the last moment.

The next day (tomorrow), this EXE is going to be presented to the major donors of nearly all charities working in Northern Uganda (people displaced by the decades-long war).

My friend, I thank you. The people of Northern Uganda thank you. God bless you tremendously!
Posted by Matovu Lwanga on 25 Oct 2010 at 4:34am
That's great, man ... you help me so much :)

Thank you so much ...
Posted by Nikola Vujovic on 5 Nov 2010 at 7:47am
your the man...... its beautifully run....

thanks a lot.....
Posted by alv on 6 Dec 2010 at 8:49pm
proxy.exe is great! It is surely wipe off my problem to run PDF files in Interactive CD.
Posted by mawi wijna on 11 Dec 2010 at 4:29am
thanks a lot man..

it a really nice.. i was trying to solve.. 100s of sites have given exmaple.. but no one said about bug of cs3.. really nice..
Posted by vijay on 11 Jan 2011 at 2:20pm
Thank you SO much for this proxy method! Even a newbie like me was able to understand and implement this! You saved the day! Now I just have to figure out the mac side...
I did run into one problem- I am using this to open a wmv file in windows media player, and it will not open full screen. I thought the 'fscommand' would have done this automatically, but no such luck. Is there a way to make the wmv movie open in full screen mode?
Posted by ninjen on 23 Jan 2011 at 3:31pm
You should be able to add "/fullscreen" to the Windows Media player command line to get it to open in fullscreen mode.
Posted by Tim on 23 Jan 2011 at 4:59pm
You're great man!!!!!!!!!!!!!!!!! i can't tell you how happy you made me :))))))))) i was trying opening the new window for days and that really gets on my nerves :D thans a lot
Posted by Marti on 12 Mar 2011 at 4:50am
well, the list is huge but I can't go away without giving you my thanks for your help; unfortunatelly adobe seems not want to help us with this minor things.

thanks a lot!
Posted by Saulo on 18 Apr 2011 at 2:51pm
You are indeed a great man! I shall sleep tonight, thank you!
Posted by Derrin on 18 Apr 2011 at 4:25pm
Tim, it works great, and u r The Genius!

it works great on XP and Win 7 x32, but does it work on Win 7 x64? I have some problems with x64. How can I force it run on 7 x64? It just keeps silent... (((
Posted by Dmitriy on 3 May 2011 at 7:43am
I'll test it on Windows 7 64-bit again, but I'm pretty sure it was working there too. Let's talk in the forums in the Free Tools section.
Posted by Tim on 3 May 2011 at 9:23am
thank you a lot, you save my live!
Posted by someguy on 9 May 2011 at 6:09pm
hey man awesome work.......... even now years on saving ppls headaches :)
Posted by Oliver LW on 19 Jun 2011 at 12:07pm
ThankYou very helpfull............
Posted by Popo on 6 Jul 2011 at 6:17am
So helpfull. I was about to split my pc with an axe!!! Really nice!
Posted by Sotiris Boukouvalas on 11 Aug 2011 at 2:29pm
Thank you soo! much for sharing this... But I have another problem, how do you do it on MAC OS? TIA :)
Posted by Celso Tengonciang on 16 Aug 2011 at 3:33am
On OSX you can use a compiled AppleScript instead of proxy.exe.
Posted by Tim on 16 Aug 2011 at 6:20am
Thank you very much, very straightforward and perfectly working. Solved all my problems :D
Posted by Andrei on 25 Aug 2011 at 2:51am
Hello and thank you so much for this tool!

Question: I have a .bat file that calls .exe file and then waiting for its completion. When the .exe file is finished, the .bat file makes few more steps and only after this it closes. But it seems that after a few seconds proxy.exe kills cmd.exe process which it started itself.
Is there any way to do something that the proxy.exe does not close process cmd.exe?

Thank you!
Posted by Mike on 22 Oct 2011 at 2:42am
You are correct, proxy kills the instance of CMD.EXE if the launched process doesn't end after about 5 seconds. It does this to protect you from applications that never quit. It prevents the hidden instance of CMD.EXE from hanging around forever. You just need a custom version of the proxy tool that doesn't do this, fire off an email to support at and I'll get you hooked up.
Posted by Tim on 22 Oct 2011 at 2:42am
Dear Sir, I read your post, I think you can help me.
I want to make a CD Project, the menu I made in flash with 4 buttons named: "VIDEO" "PRESENTATION" "CATALOGUE" "LOCATION MAP"
The video file path is "video\video.vob"
Catalogue file path is" Catalogue\Ct.pdf"
Presentatiopn file path is "Presentation\Pr.pps"

Now lets come to the point, I want to give on release comman for VIDEO button and the video shall play in dvd player etc..
I want the click on CATALOGUE button to open Ct.pdf
and so on the same for others, Please send me the details how to anable me make this project,
the complete action script used in Flash MX Pro version 8.
I can link the buttons to the url but I want the buttons to open files from local folder. Plz save me save my status:) you are life saver as I read above
Posted by Firooz on 27 Dec 2011 at 3:43pm
You're going to need one BAT file for each button, the script that goes in the BAT file depends on what you want to do (open a video, launch a PDF, etc). The ActionScript in each case will be the same, a simple fscommand("exec", "whatever.bat") in response to a button press, click or release (your choice).
Posted by tim on 27 Dec 2011 at 4:06pm
Thanks a lot
Posted by Aparna Murthy on 14 Jun 2012 at 3:26am
This method is still solid and working after 5 years! Thank you so much! This is truely a life-saver!!
Posted by yu on 9 Jul 2012 at 3:24pm

Leave a Comment

Comments are now closed for this post.

← Back

copyright © 2000-2015 Northcode Inc  ·  all rights reserved  ·  contact us