This example describes the Basics for building the Hyperlink using GWT. The steps involved in Building the Hyperlink are described below:-
private Label label = new Label()
Here we are declaring label. Label is a widget that
contains text.
Hyperlink link0 = new Hyperlink("Delhi",
"Delhi")
Creating Hyperlink object named 'link0'. Hyperlink is a class or a widget that serves as an "internal" hyperlink
VerticalPanel panel = new VerticalPanel()
Creating Vertical panel. Vertical panel is a class
that lays all of its widgets out in a single vertical column.
panel.add(label)
This is the method of class Vertical panel. By
using this method we added a label to the Panel
History.addHistoryListener(this)
History is a class that allows us to interact with the browser's history stack.
addHistoryListener() is a method of this class to adds a listener to the browser's history
stack.
HyperLinkExample.java
|
Main.gwt.xml
|
Output of the program

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.
Ask Questions? Discuss: Creating Hyperlink using GWT View All Comments
Post your Comment