hi all,, im working at a project which must: take student homework then check if the homework is correct or not ex: student homework saved on a file name "hwfile.java" so my program will compile and then run this file and get the output,, then compair this output with the correct answer(correct answer entered by techer and saved on text file...) my problem is how to use Runtime.getRuntime().exec(...) to combile and run a file??? what is the parameter will be " Runtime.getRuntime().exec(???) " ?? HELP
but what if i need to pass a value to the other program like if :
how can i run it?
Joined: Dec 29, 2004
Then you need to use the getOutputStream()
Joined: May 18, 2005
im sorry i asked to much but can i pass the arguments in someway like: Process pr=Runtime.getRuntime().exec("java test 10 20"); and the a=args; b= args?? or it done in diffrent way [ May 19, 2005: Message edited by: nana mm ]