Dear all I want to execute a EXE file in Java, but I was not able to do it correctly. Originally, in DOS command prompt, my command is like this:
C:>\crf_test.exe model <inputfile.txt> outputfile.txt
Note: the input file name must be place in the brackets <>. It always gave me good results when run it in DOS window.
When I want my java program to call above command, I do like this:
Process p = Runtime.getRuntime().exec("crf_test.exe model <inputfile.txt> outputfile.txt");
However, the output of this command is "no such file or directory: " I guest Java doesn't like the brackets <> in DOS command. I also remove <> out, but exe file did not accept that. So now how can I deal with this problem? Please give me a sollution Thank you much much