This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes GWT and the fly likes GWT - No source code is available error. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » GWT
Bookmark "GWT - No source code is available error." Watch "GWT - No source code is available error." New topic
Author

GWT - No source code is available error.

Adi Vicks
Greenhorn

Joined: Feb 23, 2012
Posts: 9
I am facing one error while running my GWT application.

Line 62: No source code is available for type com.abc.PQR; did you forget to inherit a required module?

Note: PQR is a class present in another project/directory. I have added that project's jar to my build path so didn't get any compilation error in eclipse. But seems like jetty deployment not working. I am using google plugin for eclipse to develope this application. Both the projects are under same folder.

I added the project as reference project to my project but no luck.

Any help ?
Tina Smith
Ranch Hand

Joined: Jul 21, 2011
Posts: 171
    
    5

To make the Java files available to the GWT compiler you need to

Create a gwt.xml file in the Java project / jar file which you want to use - This will instruct the GWT compiler to use the listed classes.

Use the included library via the inherit definition

If you are using a jar file you also need to include the source files in the jar

From: http://www.vogella.de/articles/GWTModules/article.html

If you don't have access to the Java project/jar file, or don't want to explicitly link it to GWT, you can include the gwt.xml file in the same package within your GWT project rather than within the other project.


Everything is theoretically impossible, until it is done. ~Robert A. Heinlein
Adi Vicks
Greenhorn

Joined: Feb 23, 2012
Posts: 9
Thanks for the link. Its working now. Also I forgot to add the dependency jars in the war/web-inf/lib folder.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: GWT - No source code is available error.
 
Similar Threads
Rome and GWT
OEPE, already set up weblogic, but cannot add gwt project to the server
Help please with GWT Sql Connection ...
GWT maven app not starting
GWT with arrayDeque and StringTokenizer Problem