PDA

View Full Version : Error showing page



djesus
25 Jun 2008, 12:49 AM
Hello all, I congratulate for your great work! I try this example:


package demo.app.client;

import com.extjs.gxt.ui.client.widget.ContentPanel;
import com.extjs.gxt.ui.client.widget.LayoutContainer;
import com.extjs.gxt.ui.client.widget.Viewport;
import com.extjs.gxt.ui.client.widget.layout.CenterLayout;
import com.extjs.gxt.ui.client.widget.layout.FillLayout;
import com.extjs.gxt.ui.client.widget.layout.FitLayout;
import com.google.gwt.core.client.EntryPoint;
import com.google.gwt.user.client.ui.RootPanel;

/**
*
* @author djesus
*/
public class App extends LayoutContainer implements EntryPoint {

/**
* The entry point method, called automatically by loading a module
* that declares an implementing class as an entry-point
*/
public void onModuleLoad() {
Viewport v = new Viewport();
v.setLayout(new FitLayout());
v.add(this);
RootPanel.get().add(v);
}

public App() {
// next line is only used to pass layout to containing container
// this will have NO effect outside of the explorer demo
setData("layout", new FillLayout());
setLayout(new CenterLayout());
ContentPanel panel = new ContentPanel();
panel.setBodyStyle("padding: 6px");
panel.setFrame(true);
panel.setHeading("CenterLayout");
panel.addText("I should be centered");
panel.setWidth(200);

add(panel);
}
}
but when run I get as show the file attached.

Is there to add any code to locate the css files?

Thanks in advance

gslender
25 Jun 2008, 1:52 AM
css is part of the html file and needs to be as follows...



<link rel="stylesheet" type="text/css" href="css/ext-all.css" />

djesus
25 Jun 2008, 2:15 AM
Thanks a lot, I am beginner, sorry for my ignorance