Pls Help:Running a C executable from my Java Code
I am trying to run a C/C++ executable a.out from my Java code but its not working pls help me out...Its very very important
I am writing a segment of the code pls point out if i am making any mistakes
publicvoid itemStateChanged(ItemEvent a)
{
int i=c1.getSelectedIndex();
Runtime r=Runtime.getRuntime();
try
{
if(i==0);
if(i==1);
if(i==2);
if(i==3)
{
r.exec("./prog/a.out");
System.exit(0);
}
}catch(Exception e){}
}
I am working in UNIX enviornment

