3 Replies Latest reply on Jun 27, 2009 8:24 AM by kglad

    Help with calling a batch file from projector

    bschneid

      Hi all.  I have been asking a fair number of questions here recently and have been very pleased with the responses, so here is one more for you.  Hopefully I can get another solution. :]

       

      I have a flash project acting like a menu and being published as an .exe (projector).  In this file, I have a button with the following code:


      button1.onRelease=function(){

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

      }

       

      I have an fscommand folder (in the same directory as my flash file) which contains the openfiles.bat, with one line:

       

      start myfile.txt

       

      myfile.txt is also located in the fscommand folder.  When I simply click on this batch file and run it, the text file opens as it should.  However, when I click the button in my flash file, a command prompt window flashes too quickly to see with some sort of error message.  It says something about not finding a certain directory and defaulting to the windows directory.  I'm assuming it cannot find either my batch file or my text file.  I am under the impression that as long as everything is in the fscommand folder it should work properly.  Can anyone offer me advice?  Thanks!