This week's book giveaway is in the Agile and other Processes forum.
We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line!
See this thread for details.
The moose likes Applets and the fly likes Applets and Hyperlinks Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Applets
Reply Bookmark "Applets and Hyperlinks" Watch "Applets and Hyperlinks" New topic
Author

Applets and Hyperlinks

Sam Bluesman
Ranch Hand

Joined: Nov 21, 2004
Posts: 188
Can u attach a hyperlink to an applet so that when a user clicks anywhere on the applet it takes the user to a different website or webpage?

If so...how?


Moosey knows best
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8265

Please change your displayed name to conform to our
naming policy. In short, your name must be a first name and last name, separated by a space and not obviously fake.
Now, about your question. No, but you can do something similar by calling AppletContext.showDocument() to load a new URL in the browser.


"blabbing like a narcissistic fool with a superiority complex" ~ N.A.
[How To Ask Questions On JavaRanch]
Swathi Prakash
Ranch Hand

Joined: Jan 18, 2005
Posts: 49
urlField = new TextField("http://localhost/");

userUrl = new URL(s);
urlField.setText(userUrl.toString());
getAppletContext().showDocument(userUrl, "_blank");
Sam Bluesman
Ranch Hand

Joined: Nov 21, 2004
Posts: 188
That is my real name: Mr. Sam Bluesman
Sam Bluesman
Ranch Hand

Joined: Nov 21, 2004
Posts: 188
is that better? Or would you like me to put Samual? i wouldnt want you to get upset
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8265

We ask that people use their real names because we want this place to be friendly to the newcomer and people seem to take the anynomity of the internet as a license to be short-tempered and insulting. Thanks for making the change and enjoy the Ranch.
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Applets and Hyperlinks
 
Similar Threads
applet question
WebPage can't run applet as signed after another signed applet is disabled
applet and jsp - retain values in applet ?? PLEASE HELP!
'signing' and 'grant'
Tif Image printing from applet