Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Other Java > Java GUI
|
Java GUI Discussions specific to programming Java GUI.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Java GUI section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 17th, 2003, 01:12 AM
Registered User
 
Join Date: Jun 2003
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Run a web page in java application on button click

Respected sirs/madam

  I am in situation wherein i have to display an help page written as an HTML file to the user when he clicks on a menu item.My program happens to be an application.I just don't know which class to use or how i get this done.I'd be greatful to you if you could get me a solution.

Thank you.
 
Old June 17th, 2003, 04:10 AM
Authorized User
 
Join Date: May 2003
Posts: 50
Thanks: 0
Thanked 0 Times in 0 Posts
Default

hi

You can display HTML content in Java Applications using the JEditorPane Class this Class supports text/plain ,text/html and text/rtf content type just go through the API documentation provided by SUN.

Yashraj Chauhan
Java\J2EE Specialist
Wiley Support Team
 
Old June 28th, 2003, 08:26 AM
Registered User
 
Join Date: Jun 2003
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default


Yashraj Chauhan, I think you did not understand the question asked by
mathsyaka. He just wanted to know if there is anyway he could load up a browser when a button is pressed from his application. He was not looking for a class the supports html.

I wish I knew how to do it, I would have to him. So, if you think you know it, just show him a typical example. Thank you for your time.

Evans

 
Old July 2nd, 2003, 11:40 AM
Registered User
 
Join Date: Jul 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

try looking into the Runtime class, it has a exec method that you could use to shell out commands to dos, it'll launch the web browser for you, but this might only work for windows, not sure about other OS. to test is manually open dos and type something like:
start www.yahoo.com
this should open a browser with yahoo.





Similar Threads
Thread Thread Starter Forum Replies Last Post
click the button above and redirect another page crmpicco Perl 2 November 16th, 2006 08:46 AM
don't want the page refresh on button click swati_joshi ASP.NET 1.0 and 1.1 Basics 4 July 31st, 2006 04:37 AM
How to Click a web button using VB code AJD Access VBA 6 June 6th, 2006 07:32 AM
How to Click a button on a web page in VB code AJD Beginning VB 6 0 June 2nd, 2006 12:08 PM
rebind dataset from web service after click button blur_ivy .NET Web Services 2 April 15th, 2005 09:09 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.