PDA

View Full Version : Getting started with netbeans 6.8 and GWT-ext



udayanga
17 Jan 2010, 9:18 PM
hi,

I'm new to gwt-ext. :)

I used netbeans 6.8 to create a simple project(add new combo box).
but it's not compile.(:|

I have add and set all the paths and libraries.
this is my code segment in the onModuleLoad() method.



public void onModuleLoad() {
final Label label = new Label("Hello, GWT!!!");
final Button button = new Button("Click me!");
ComboBox c = new ComboBox();
c.setVisible(true);

button.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
label.setVisible(!label.isVisible());
}
});
RootPanel.get().add(c);
RootPanel.get().add(label);
}



This is the compilation error :-



GWT installation directory: F:\GWT\gwt-2.0.0\gwt-2.0.0
do-gwt-compile-15:
do-gwt-compile-16:
do-gwt-compile-17:
do-gwt-compile-20:
GWT Compiling client-side code.
Compiling module org.yournamehere.Main
Validating newly compiled units
[ERROR] Errors in 'file:/C:/Documents%20and%20Settings/udayanga/My%20Documents/NetBeansProjects/WebApplication1/src/java/org/yournamehere/client/MainEntryPoint.java'
[ERROR] Line 34: No source code is available for type com.extjs.gxt.ui.client.widget.form.ComboBox<D>; did you forget to inherit a required module?
Finding entry point classes
[ERROR] Unable to find type 'org.yournamehere.client.MainEntryPoint'
[ERROR] Hint: Previous compiler errors may have made this type unavailable
[ERROR] Hint: Check the inheritance chain from your module; it may not be inheriting a required module or a module may not be adding its source path entries properly
C:\Documents and Settings\udayanga\My Documents\NetBeansProjects\WebApplication1\nbproject\build-gwt.xml:134: The following error occurred while executing this line:
C:\Documents and Settings\udayanga\My Documents\NetBeansProjects\WebApplication1\nbproject\build-gwt.xml:232: Java returned: 1
BUILD FAILED (total time: 6 seconds)



Please explain me how to add codes in the
http://www.extjs.com/explorer/#combobox
link into my netbeans project.

thanks.

keithoth
18 Jan 2010, 1:25 AM
I am working with Netbeans and Grails. I can't get code completion to work with ExtJS in external JavaScript files or gsp files. If I create a standard Java Web Project it works. It even works with Ruby on Rails. I can't however get it to work in Grails which is what I am currently using. Does anyone know how to get this to work.

terciofilho
18 Jan 2010, 4:01 AM
Did you inherit GXT module?

Add this to you MODULE.gwt.xml.


<inherits name='com.extjs.gxt.ui.GXT' />

Arno.Nyhm
18 Jan 2010, 8:26 AM
you can also install the GWT4NB (https://gwt4nb.dev.java.net/) plugin for netbeans.

udayanga
18 Jan 2010, 8:48 AM
Can u tel me how to develop a simple form using showcase component?
I tried it but its not working.

Arno.Nyhm
19 Jan 2010, 2:49 AM
my suggested steps for you:

1) install GWT4NB
2) create a complete new project only for gwt
3) get it running

after this enable the gxt:
4) include gxt.jar in the library
5) include the gxt inherits in yourapp.gwt.xml
6) copy resources to your project
7) include the resources in yourapp.html
8) check with firebug and / or WebDeveloper Plugin if all classes and resources are loaded
9) then create your first GXT window


10) as last point copy some files from the examples.


please go it step by step and let us now at which point you stuck.
and please: do not write only "it is not working"! with this line nobody can and not will help you.
better: describe your current state. show us your current code / make a screenshot / copy the messages from netbeans and stacktraces (from netbeans output / console / Tomcat log (or other webserver log) / GWT console log