Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    smart gwt with eclipse example step by step i need

    plz give any good tutorial step by step guid how to use smart gwt with eclipse.

    i have done already gwt and gwt extention with eclipse
    but i am not able to smart gwt simple example.
    Hence plz send any good tutorial to develop smart gwt with eclipse.

    #2
    you should provide a little more information
    what version of gwt you use ?
    if 1.6 do you intend to use google eclipse plugin or webAppcreator ?
    if 1.5 do you have cypal plugin ?

    Comment


      #3
      Please see sticky thread on this.

      Comment


        #4
        thanks for your good response.
        i am using 1.6 and using google plug-in plz mention
        what i have to do next to develop smart gwt application.plz reply

        and one more thing i dont want to install maven i dont know why maven with eclipse and smart gwt using.plz suggest and guide me.

        Comment


          #5
          So I supposed you have project gwt created by plugin in eclipse.

          1. Add to your yourmodule.gwt.xml line:
          Code:
          <inherits name="com.smartgwt.SmartGwt" />
          this will cause loading all smart client js scripts and Enterprise skin
          2. inlude in your project build path smartgwt.jar
          3. In your html file located in war directory of your project add line:
          Code:
          <script var isomorphicDir="your module name/sc/"</script>
          where your module name is exact string from rename-to attribute in your yourmodule.gwt.xml <module> tag
          4. remove all gwt servlets and lines of code added by google plugin
          5. add your own smartgwt components to root panel in onload method

          that's it

          Comment


            #6
            thank you very much.

            Comment


              #7
              i have compliled and got output for HellosmartGWt example but i am not able to run follwoing program i mean last two packages i am not able to include how i can include this package into my buildpath.i am getting error with these two.

              import com.smartgwt.sample.showcase.client.PanelFactory;
              import com.smartgwt.sample.showcase.client.ShowcasePanel;


              import com.smartgwt.client.types.Alignment;
              import com.smartgwt.client.widgets.Canvas;
              import com.smartgwt.client.widgets.Label;
              import com.smartgwt.client.widgets.layout.HStack;
              import com.smartgwt.client.widgets.layout.VStack;
              import com.smartgwt.sample.showcase.client.PanelFactory;
              import com.smartgwt.sample.showcase.client.ShowcasePanel;

              public class StackSample implements EntryPoint {

              public void onModuleLoad() {

              Canvas canvas = new Canvas();

              VStack vStack = new VStack();
              vStack.setShowEdges(true);
              vStack.setWidth(150);
              vStack.setMembersMargin(5);
              vStack.setLayoutMargin(10);
              vStack.addMember(new BlueBox(null, 40, "height 40"));
              vStack.addMember(new BlueBox(null, 80, "height 80"));
              vStack.addMember(new BlueBox(null, 160, "height 160"));
              canvas.addChild(vStack);

              HStack hStack = new HStack();
              hStack.setLeft(170);
              hStack.setShowEdges(true);
              hStack.setHeight(150);
              hStack.setMembersMargin(5);
              hStack.setLayoutMargin(10);
              hStack.addMember(new BlueBox(60, null, "width 60"));
              hStack.addMember(new BlueBox(80, null, "width 80"));
              hStack.addMember(new BlueBox(160, null, "width 160"));
              canvas.addChild(hStack);

              canvas.draw();
              }

              class BlueBox extends Label {

              public BlueBox(String contents) {
              setAlign(Alignment.CENTER);
              setBorder("1px solid #808080");
              setBackgroundColor("lightblue");
              setContents(contents);
              }

              public BlueBox(Integer width, Integer height, String contents) {
              this(contents);
              if (width != null) setWidth(width);
              if (height != null) setHeight(height);
              }
              }

              }

              Comment


                #8
                Why are you including the following imports??

                import com.smartgwt.sample.showcase.client.PanelFactory;
                import com.smartgwt.sample.showcase.client.ShowcasePanel;

                They are part of the Showcase samples and not part of the SmartGWT library jar.

                If you want to start off with one of the existing Showcase samples, click the View Source button, and use that code as a starting point.

                Also please enclose any code within [code ] [/code] tags.

                Sanjiv

                Comment


                  #9
                  Originally posted by lazinskip
                  So I supposed you have project gwt created by plugin in eclipse.

                  1. Add to your yourmodule.gwt.xml line:
                  Code:
                  <inherits name="com.smartgwt.SmartGwt" />
                  this will cause loading all smart client js scripts and Enterprise skin
                  2. inlude in your project build path smartgwt.jar
                  3. In your html file located in war directory of your project add line:
                  Code:
                  <script var isomorphicDir="your module name/sc/"</script>
                  where your module name is exact string from rename-to attribute in your yourmodule.gwt.xml <module> tag
                  4. remove all gwt servlets and lines of code added by google plugin
                  5. add your own smartgwt components to root panel in onload method

                  that's it
                  Hi.
                  I'm completely new on GWT and Smart.
                  I run through all your steps. My Code looks like that:

                  Code:
                  public class Test3 implements EntryPoint {
                  	
                  	/**
                  	 * This is the entry point method.
                  	 */
                  	public void onModuleLoad() {
                  		IButton btn = new IButton("I am a Button"); 
                  		RootPanel.get().add(btn);
                  	}
                  }
                  But when i start the GWT hosted browser (also when i compile the project and run it in a normal browser) the button has no image.
                  The console says:

                  10.06.2009 15:38:00 com.google.appengine.tools.development.LocalResourceFileServlet doGet
                  WARNING: No file found for: /sc/skins/Enterprise/images/blank.gif

                  What am I doing wrong?

                  I am using:
                  WinXP
                  GWT 1.6
                  smartgwt 1.1

                  Comment


                    #10
                    Originally posted by lazinskip

                    Code:
                    <script var isomorphicDir="your module name/sc/"</script>
                    I found the error:
                    you forgot to close the script tag it should be:

                    <script> var isomorphicDir="your module name/sc/"</script>

                    Comment


                      #11
                      That also does not work.
                      It works fine with only following tag:
                      <script>
                      var isomorphicDir="your module name/sc/";
                      </script>

                      Comment


                        #12
                        There is "-server Specifies a different embedded web server to run (must implement ServletContainerLauncher)" but this question is rather related to GWT not SmartGwt

                        Comment


                          #13
                          html,php,smartgwt

                          i have test.php
                          i like to include samrtgwt file.
                          i added in this way

                          <html>
                          <head>
                          <meta http-equiv="content-type" content="text/html; charset=UTF-8">

                          <!-- -->
                          <!-- Consider inlining CSS to reduce the number of requested files -->
                          <!-- -->
                          <link type="text/css" rel="stylesheet" href="ContactStep1.css">

                          <!-- -->
                          <!-- Any title is fine -->
                          <!-- -->
                          <title>Wrapper HTML for ContactStep1</title>

                          <!-- -->
                          <!-- This script loads your compiled module. -->
                          <!-- If you add any GWT meta tags, they must -->
                          <!-- be added before this line. -->
                          <!-- -->
                          <script> var isomorphicDir="jp.co.ifcreate.contact.ContactStep1/sc/"</script>
                          <script language="javascript" src="jp.co.ifcreate.contact.ContactStep1/jp.co.ifcreate.contact.ContactStep1.nocache.js"></script>
                          </head>

                          <body>

                          </body>
                          </html>


                          I executed the abobe file as test.html but OK
                          but if added the above lines in test.php file then blank line appears.
                          I did not understand , is there any errors??

                          Comment

                          Working...
                          X