203.197.57.46 writes:
How do I lauch a Browser with a specified URL through a Java Application on click of a Button.
I have tried in many ways like :
* Making a applet an application as well as applet.
* creating an instance of applet in a frame , adding it to frame and explicity invoking init amd start.
hema
203.129.225.217 writes:
Did you create a html file for your applet?? Please explain what exactly u are trying to do! U want that ur program itself should launch the browser or what??
Anand Gore
152.173.59.48 writes:
Allowing a java app to control another program has to be done through the use of the java.lang.Runtime class.
Use something like
new Process pBrowser = new Runtime.exec("c:\netscape\comm\program\netscape.exe www.yahoo.com");
of course, you have to supply the correct command string to run
MikeD
152.173.59.48 writes:
it's
new Process pBrowser = new Runtime.getRuntime().exec("c:\netscape\comm\program\netscape.exe www.yahoo.com");
MikeD