GWT 2.0 – First look and Guide
Today I have been testing setting up a new 2.0 Google Web Toolkit.
GWT 2.0 is currently on Milestone release so I thought I’d give it a try. I especially want to try out the GWT declarative UI features
I’ll go through the steps I have made to start the project. (I’m assuming you are using Eclipse as your IDE)
Step 1
If you haven’t already download and install the GWT and GAE (Google App Engine) plugins for Eclipse.
Step 2
Download the GWT 2.0 latest release candidate
Step 3
Add the new GWT 2.0 SDK to your IDE.
To do so go to your Eclipse Settings/Preferences window and choose Google from the menu on the left hand side.
You’ll see different versions of GWT listed. Click the ‘Add’ button to add the 2.0 SDK
From here you can browse and choose the GWT 2.0 SDK folder and enter GWT 2.0 in the name field
Once you have done so click OK
Step 4
Create a new Web Application Project
Click File>New>Web Application Project…
After populating your Project and Package name under Google SDK’s – Google Web Toolkit choose ‘Use specific SDK’ and choose your GWT 2.0 from the drop down list. You can leave the Google App Engine version as it is. Click OK to create your project.
Step 5
Running the application
In Eclipse make sure you project is selected and choose ‘Run’ from the menu
Click on ‘Open Run dialog…’
Down the left side you will see ‘Web Application’ select that and click ‘Run’
You’ll then get an error similar to the following:
Using a browser with the GWT Development Plugin, please browse to the following URL: http://localhost:8080/WebApplication.html?gwt.hosted=192.168.1.10:9997
If you then browse to the URL it gives you will see a page telling you that you need to download and install a plugin for your browser
Download and install the plugin for your chosen browser
Once you have done so – close and quit the browser
Also on Eclipse make sure and stop the current running ‘Web Application’.
Then restart ‘Web Application’ and when it gives you the same error navigate your browser to the URL given and this time you should see the GWT application correctly displayed
