View Full Version : Asynctreegrid is empty, and migration from GXT 2.1.1(gwt 1.7) to GXT 2.2.5(gwt 2.4)

8 Feb 2012, 11:50 AM
I'm trying to upgrade my code from gxt2.1.1 with gwt 1.7 to gxt 2.2.5 with gwt 2.4, but I run into a few problems, such as blank pages.

To narrow down to the issue, I used only the sample code from gxt 2.2.5.zip to recreate the problem. It seems that Asynctreegrid is empty while other grids, such as Basic Grid, are fine.

Asynctreegrid is using the remote data, so it might be related RPC call. But I don't know where the problem come from and how to fix it. Any suggestion to fix it?


The following is the URL and the screenshot for Asynctreegrid:


8 Feb 2012, 2:43 PM
Sorry. Asynctreegrid is not working because I forgot to add the servlet/mapping in web.xml.

My old project is still not working...but I'm getting closer. It looks I have to use GXT.getModuleBaseURL() for the remote service.

10 Feb 2012, 9:19 AM
The problem is from the remote service URL, which will be will be empty if I don't use "ServiceDefTarget" to set the service entry point. If I uncommented the three lines below, it works fine.

In Explorer.java from GXT 2.2.5, I don't see any need to use ServiceDefTarget. Can you please explain what has happened? When should I use ServiceDefTarget? I must miss something importatnt.

=== Code sample from my customized Explorer.java ===

FRMServiceAsync service = (FRMServiceAsync) GWT.create(FRMService.class);
//ServiceDefTarget endpoint = (ServiceDefTarget) service;
//String moduleRelativeURL = "service";
Registry.register(FRM.SERVICE, service);

=== Code sample from Explorer.java in GXT 2.2.5 ===

ExampleServiceAsync service = (ExampleServiceAsync) GWT.create(ExampleService.class);

SERVICE, service);