Running Java file and capturing output

M

marie

Hi,

I need to call a Java class and capture the output it generates and
send it to a file.
I tried using the system command:

system("/usr/local/bin/java, </var/log/MyJavaClass', &> /var/tmp/
history.html");

However i get the following error:
sh: /var/log/MyJavaClass, &> /var/tmp/history.html: cannot open

Does anyone know what I am doing wrong?

I am running this script from Unix,

Marie
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,768
Messages
2,569,575
Members
45,053
Latest member
billing-software

Latest Threads

Top