Win a copy of Svelte and Sapper in Action this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

URL redirection Program not working.

 
Ranch Hand
Posts: 223
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


what is wrong with this program? Seems ok, But I type:
http://www.google.com

But nothing happens.
 
Rancher
Posts: 43016
76
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Works fine for me. Which browser and JRE are you using? Are there any messages in the Java Console?
[ May 23, 2007: Message edited by: Ulf Dittmer ]
 
v ray
Ranch Hand
Posts: 223
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Really? its working fine for you? I am trying to execute it through eclipse as a java applet, and does it matter if my default browser is firefox? I also have IE, but not sure which one the applet would try to use..
Also, there was no message on the console, the applet loads properly, but when i click on "go there", nothing happens, no response.
 
Ulf Dittmer
Rancher
Posts: 43016
76
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Eclipse is not a browser. From the javadocs of the showDocument method:

This method may be ignored by applet contexts that are not browsers.


What happens if you run the applet in a browser?
 
v ray
Ranch Hand
Posts: 223
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry if this sounds stupid, but how do I run the applet in a browser?
 
Ulf Dittmer
Rancher
Posts: 43016
76
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You need an HTML file that contains an APPLET tag.
    Bookmark Topic Watch Topic
  • New Topic