title: Getting javascript error while using smart-gwt
body: <p>I am using a combination of gwt and smart gwt. However i get the following eror whenever my page loads. please help me with fixing this. .
  Please find the attached screenshot for the image of the popup error for the same</p>
  
  <pre><code>15:06:02.097 [ERROR] [detectfiles] 15:06:02.097:TMR5:WARN:Log:Error:
      'Object required'
      in /sc/modules/ISC_Core.js
      at line 1782
      [c]Element.getOffsetLeft(_1=&amp;gt;[DIVElement]{ID:isc_0})
      [c]Element.getOffset(_1=&amp;gt;&amp;quot;left&amp;quot;, _2=&amp;gt;[ImgButton ID:isc_ImgButton_0], _3=&amp;gt;undef, _4=&amp;gt;false, _5=&amp;gt;true)
      Canvas.getLeftOffset(_1=&amp;gt;undef)
      Canvas.getPageLeft()
      Canvas.$414(null, undef)
      [c]Page.handleEvent(_1=&amp;gt;null, _2=&amp;gt;&amp;quot;resize&amp;quot;, _3=&amp;gt;undef)
      [c]EventHandler.$78p(_1=&amp;gt;&amp;quot;landscape&amp;quot;)
      [c]EventHandler.$hr(_1=&amp;gt;undef)
      callback(undefined=&amp;gt;undef)
          &amp;quot;isc.EH.$hr()&amp;quot;
      [c]Class.fireCallback(_1=&amp;gt;&amp;quot;isc.EH.$hr()&amp;quot;, _2=&amp;gt;undef, _3=&amp;gt;Array[0], _4=&amp;gt;Obj{length:2}, _5=&amp;gt;true) on [Class Timer]
      [c]Timer.$in(_1=&amp;gt;&amp;quot;$ir28&amp;quot;)
      anonymous()
          &amp;quot;isc.Timer.$in('$ir28')&amp;quot;
  
  com.smartgwt.client.core.JsObject$SGWT_WARN: 15:06:02.097:TMR5:WARN:Log:Error:
      'Object required'
      in /sc/modules/ISC_Core.js
      at line 1782
      [c]Element.getOffsetLeft(_1=&amp;gt;[DIVElement]{ID:isc_0})
      [c]Element.getOffset(_1=&amp;gt;&amp;quot;left&amp;quot;, _2=&amp;gt;[ImgButton ID:isc_ImgButton_0], _3=&amp;gt;undef, _4=&amp;gt;false, _5=&amp;gt;true)
      Canvas.getLeftOffset(_1=&amp;gt;undef)
      Canvas.getPageLeft()
      Canvas.$414(null, undef)
      [c]Page.handleEvent(_1=&amp;gt;null, _2=&amp;gt;&amp;quot;resize&amp;quot;, _3=&amp;gt;undef)
      [c]EventHandler.$78p(_1=&amp;gt;&amp;quot;landscape&amp;quot;)
      [c]EventHandler.$hr(_1=&amp;gt;undef)
      callback(undefined=&amp;gt;undef)
          &amp;quot;isc.EH.$hr()&amp;quot;
      [c]Class.fireCallback(_1=&amp;gt;&amp;quot;isc.EH.$hr()&amp;quot;, _2=&amp;gt;undef, _3=&amp;gt;Array[0], _4=&amp;gt;Obj{length:2}, _5=&amp;gt;true) on [Class Timer]
      [c]Timer.$in(_1=&amp;gt;&amp;quot;$ir28&amp;quot;)
      anonymous()
          &amp;quot;isc.Timer.$in('$ir28')&amp;quot;
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
      at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:105)
      at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
      at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
      at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:292)
      at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:546)
      at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:363)
      at java.lang.Thread.run(Thread.java:662)
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/zOnpp.jpg" alt="Please find the attached screenshot for the image of the popup error for the same"></p>
  
  <p><img src="https://i.stack.imgur.com/Fgrq0.jpg" alt="smart-gwt error"></p>
  
  <p>Here is a piece of code in which I am using TreeGrid inside a popup</p>
  
  <pre><code>private PopupPanel createConsoPopup() {
      final PopupPanel consoPopup = new PopupPanel();
      consoPopup.setAnimationEnabled(true);
      consoPopup.setAutoHideEnabled(true);
      VerticalPanel consoContent = new VerticalPanel();
      VEPConsoTree consoTree = new VEPConsoTree(lineTreeNode, vepConsoTree);
      vepConsoTree = consoTree.getCheckStationTree();
      vepConsoTree.addSelectionChangedHandler(new SelectionChangedHandler() {
          @Override
          public void onSelectionChanged(SelectionEvent event) {
              ((TextBox)flexTable.getWidget(selectedRowNum,         0)).setText(vepConsoTree.getSelectedRecord().getAttribute("vepAreaName")+"_"+vepConsoTree.getSelectedRecord().getAttribute("checkStationName"));
              consoPopup.hide();
  
          }
      });
      consoContent.add(consoTree);
      consoPopup.add(consoContent);
      return consoPopup;
  }
  </code></pre>
  
  <p>Following is my VEPConsoTree class:</p>
  
  <pre><code>package com.renault.veppwrstats.client;
  
  import com.google.gwt.user.client.ui.Composite;
  import com.smartgwt.client.types.TreeModelType;
  import com.smartgwt.client.widgets.events.DrawEvent;
  import com.smartgwt.client.widgets.events.DrawHandler;
  import com.smartgwt.client.widgets.tree.Tree;
  import com.smartgwt.client.widgets.tree.TreeGrid;
  import com.smartgwt.client.widgets.tree.TreeNode;
  
  public class VEPConsoTree extends Composite {
  
  private TreeNode[] lineTreeNode;
  private TreeGrid vepConsoTree;
  //private DFConstantsForLocale constants = GWT.create(DFConstantsForLocale.class);
  
  
  /**
   * @param lineTreeNode
   * @param vepConsoTree
   */
  public VEPConsoTree(TreeNode[] lineTreeNode, TreeGrid vepConsoTree) {
      super();
      this.lineTreeNode = lineTreeNode;
      this.vepConsoTree = vepConsoTree;
      //Grid grid = chckStatRestrictPanel();
      initWidget(vepConsoTree());
  }
  
  /**
   * This function creates checkStation Restriction Panel(tree) along with
   * Select/Unselect All button
   * 
   * @return
   */
  private TreeGrid vepConsoTree() {
      return createTreeGrid();
  }
  
  /**
   * This function creates CheckStation Restriction Tree
   * 
   * @return {@link TreeGrid}
   */
  private TreeGrid createTreeGrid() {
      final TreeGrid chckTreeGrid = new TreeGrid();
      chckTreeGrid.setHeight("269px");
      chckTreeGrid.setWidth("250px");
      chckTreeGrid.setData(createChkStationTree());
      //chckTreeGrid.setSelectionAppearance(SelectionAppearance.CHECKBOX);
      //chckTreeGrid.setShowPartialSelection(false);
      //chckTreeGrid.setCascadeSelection(true);
      chckTreeGrid.setFolderIcon(null);
      chckTreeGrid.setNodeIcon(null);
      chckTreeGrid.setShowConnectors(true);
      chckTreeGrid.setShowHeader(false);
      //addSelectionChangeHndler(chckTreeGrid);
      chckTreeGrid.addDrawHandler(new DrawHandler() {
          public void onDraw(DrawEvent event) {
              chckTreeGrid.getTree().openAll();
          }
      });
      vepConsoTree = chckTreeGrid;
      return chckTreeGrid;
  }
  
  /**
   * This function creates a basic tree
   */
  private Tree createChkStationTree() {
      Tree chckStationTree = new Tree();
      chckStationTree.setModelType(TreeModelType.PARENT);
      chckStationTree.setRootValue(1);
      chckStationTree.setIdField("id");
      chckStationTree.setOpenProperty("isOpen");
      chckStationTree.setData(lineTreeNode);
      chckStationTree.setParentIdField("parent");
      return chckStationTree;
  
  }
  
  
  /**
   * @return the vepConsoTree
   */
  public final TreeGrid getCheckStationTree() {
      return vepConsoTree;
  }
  
  /**
   * @param vepConsoTree the vepConsoTree to set
   */
  public final void setCheckStationTree(TreeGrid checkStationTree) {
      this.vepConsoTree = checkStationTree;
  }
  
  /**
   * @return the lineTreeNode
   */
  public final TreeNode[] getLineTreeNode() {
      return lineTreeNode;
  }
  
  /**
   * @param lineTreeNode the lineTreeNode to set
   */
  public final void setLineTreeNode(TreeNode[] lineTreeNode) {
      this.lineTreeNode = lineTreeNode;
  }
  </code></pre>
  
  <p>}</p>