Waiting for external .exe to finish with open()?

edited February 2016 in Programming Questions

I use open to start a .exe utility that scans in a single image to a file. If I don't add a delay after the call, the program continues before the external scan is completed and the file is not written yet! Is there a way to monitor or know when the external process is done before allowing the program to continue?


  • Answer ✓


    String[] params = { "C:/Program Files/BarTender Suite/bartend.exe", "c:/stickers/stiker01.btw" };
    Process p = Runtime.getRuntime().exec(params);
  • getting back to this. can u elaborate what params is. So this will execute the process and stop the draw loop from continuing until it is finished ?

Sign In or Register to comment.