Time

Sunday, February 7, 2010

Open .exe or other file from JAVA program

With this application you can open any .exe application like
notepad.exe (NOTEPAD)
calc.exe(CALCULATOR)
cmd.exe(COMMAND PROMPT)

AND an HTML FILE(.html)

Runtime rt=Runtime.getRuntime();
rt.exec("C:\\WINDOWS\\system32\\calc.exe");
                  OR
Runtime rt=Runtime.getRuntime();
rt.exec("cmd.exe /C start C:\\j2sdk1.4.2_03\\bin\\nil.html");

DOWNLOAD SOURCE CODE

0 comments:

Post a Comment