2 Replies Latest reply: Dec 27, 2006 2:15 AM by 807599 RSS

    Problem with exe file

    807599
      Could anyone please help me to execute an exe file "fi2t1". It needs to pick up necessary files from source and place the output files to the desination
      source     =>String FirstParam1 = "C:/Temp/sample";
      destination=>String SecondParam = "C:/Temp/sample";
      
      My code is:
      private static void compilingFiles() throws IOException 
      {
           String FirstParam1 = "C:/Temp/sample";
           String SecondParam = "C:/Temp/sample";
           Process procforopenreport2 =Runtime.getRuntime().exec("cmd /c start /MIN C:/Temp/sample/fi2t1 "+ FirstParam1, (String[])null, new File(SecondParam));
      }
      
      Currently, nothing is executing as output
        • 1. Re: Problem with exe file
          796365
          I'm not sure what you are saying the problem is - is the program not executing, or is it not producing the output you think it should?

          In the first case, place all of the parameters in an array, as shown here:
          http://forum.java.sun.com/thread.jspa?forumID=31&threadID=770327

          If the problem is everything runs but doesn't output, read this article:
          http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps.html
          • 2. Re: Problem with exe file
            807599
            The exe file "fi2t1" is supposed to pick up some needed files from the source "C:/Temp/sample" (there are already some files in the source) and should produce output files to the destination "C:/Temp/sample"