I have a perl script. I have to invoke that script from java class . Can anyone tell me how to do this with help of any link or code snippet?i did google this and got somthing like rt.exec("perl C:\\runPerl.pl"); but this is not working.
Did you literally try to add this line to your code:
then you discovered that it didn't compile and concluded that it didn't work? Or do you mean something else by "it didn't work"? If so, can you please tell use the error message you get?
You can use Runtime.exec(...) to execute system commands, for example to run the Perl interpreter (that's what the above line of code is trying to do). Ofcourse you need to have the 'perl' executable in the PATH, otherwise the system won't be able to execute it.