Google

Interview Questions Test your java skills Java API Reference Notifications Java Forums Java Examples Tell a Friend
Link to us Donate
Javagalaxy.com WWW
Subscribe Un Subscribe

Java Interview Questions on your mobileNew            

Java Interview Questions - JavaGalaxy.com

 Java Interview Questions

Back to Interview questions

AuthorMessage
JavaGalaxy

Question: How do I go from my applet to another JSP or HTML page?

Answer: Use AppletContext and invoke showDocument() on that context object. Below is sample code

URL targetURL;
String URLString = "http://localhost:8080/mypage.jsp";
AppletContext context = getAppletContext();
try
{
       targetURL = new URL(URLString);
}
catch (MalformedURLException e)
{
       e.printStackTrace();
}
context.showDocument(targetURL);

sreekala


Comment title: Plz explain Sir


Sir i would like to know about the program in detail.Plz explain it Sir.


Posted: Mon Aug 04 06:09:35 CDT 2008

Discuss in detail



Copyright © 2002 - 2010 JavaGalaxy.com,
All Rights Reserved Advertise| Feedback| Contact us| Terms of Use| Privacy Policy|

Help us to keep serving you better.
If you find any part of this site useful please support the site by linking to us