Announcement

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

    Errors in development mode for List Grid.

    Hi,

    When I use check box, frozen first column and roll over canvas together in list grid then I am getting following errors in development mode.

    00:01:04.406 [ERROR] 14:02:59.301:TMR2:WARN:Log:TypeError: this.fields[_4] is undefined
    Stack from error.stack:
    unnamed(isc_GridBody_addEmbeddedComponen) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:568
    unnamed(isc_ListGrid_addEmbeddedComponen) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:2053
    unnamed(isc_ListGrid_updateRollOverCanva) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:1831
    unnamed(isc_GridBody_updateRollOve) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:598
    unnamed(isc_GridRenderer_mouseMov) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:463
    unnamed(isc_Canvas_handleMouseMov) @ org.yournamehere.Main/sc/modules/ISC_Core.js:2097
    unnamed(isc_c_EventHandler_bubbleEven) @ org.yournamehere.Main/sc/modules/ISC_Core.js:1151
    unnamed(isc_c_EventHandler___handleMouseMov) @ org.yournamehere.Main/sc/modules/ISC_Core.js:1006
    unnamed(isc_c_EventHandler__handleMouseMov) @ org.yournamehere.Main/sc/modules/ISC_Core.js:992
    unnamed(isc_c_EventHandler__delayedMouseMov) @ org.yournamehere.Main/sc/modules/ISC_Core.js:992
    unnamed(isc_c_Class_fireCallbac) @ org.yournamehere.Main/sc/modules/ISC_Core.js:228
    unnamed(isc_c_Timer__fireTimeou) @ org.yournamehere.Main/sc/modules/ISC_Core.js:909
    unnamed() @ org.yournamehere.Main/sc/modules/ISC_Core.js:905
    unnamed() @

    <pre>com.smartgwt.client.core.JsObject$SGWT_WARN: 14:02:59.301:TMR2:WARN:Log:TypeError: this.fields[_4] is undefined
    Stack from error.stack:
    unnamed(isc_GridBody_addEmbeddedComponen) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:568
    unnamed(isc_ListGrid_addEmbeddedComponen) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:2053
    unnamed(isc_ListGrid_updateRollOverCanva) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:1831
    unnamed(isc_GridBody_updateRollOve) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:598
    unnamed(isc_GridRenderer_mouseMov) @ org.yournamehere.Main/sc/modules/ISC_Grids.js:463
    unnamed(isc_Canvas_handleMouseMov) @ org.yournamehere.Main/sc/modules/ISC_Core.js:2097
    unnamed(isc_c_EventHandler_bubbleEven) @ org.yournamehere.Main/sc/modules/ISC_Core.js:1151
    unnamed(isc_c_EventHandler___handleMouseMov) @ org.yournamehere.Main/sc/modules/ISC_Core.js:1006
    unnamed(isc_c_EventHandler__handleMouseMov) @ org.yournamehere.Main/sc/modules/ISC_Core.js:992
    unnamed(isc_c_EventHandler__delayedMouseMov) @ org.yournamehere.Main/sc/modules/ISC_Core.js:992
    unnamed(isc_c_Class_fireCallbac) @ org.yournamehere.Main/sc/modules/ISC_Core.js:228
    unnamed(isc_c_Timer__fireTimeou) @ org.yournamehere.Main/sc/modules/ISC_Core.js:909
    unnamed() @ org.yournamehere.Main/sc/modules/ISC_Core.js:905
    unnamed() @

    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:167)
    at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:281)
    at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:531)
    at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:352)
    at java.lang.Thread.run(Thread.java:619)</pre>



    I am using following browsers - FF 11 & 17 and IE 8.
    SmartClient Version: v8.3d_2012-11-19/LGPL Development Only



    Here is the sample code:-
    Code:
    package org.yournamehere.client;
    import com.google.gwt.core.client.EntryPoint;
    import com.smartgwt.client.types.*;
    import com.smartgwt.client.widgets.Canvas;
    import com.smartgwt.client.widgets.grid.ListGrid;
    import com.smartgwt.client.widgets.grid.ListGridField;
    import com.smartgwt.client.widgets.grid.ListGridRecord;
    import com.smartgwt.client.widgets.layout.HLayout;
    public class MainEntryPoint implements EntryPoint {
        private HLayout rollOverCanvas;
        private ListGridField continentField = new ListGridField("continent", "continent", 200);
        private ListGridField countryNameField = new ListGridField("countryName", "countryName", 150);
        private final ListGrid countryGrid = new ListGrid() {
            @Override
            protected Canvas getRollOverCanvas(Integer rowNum, Integer colNum) {
                return rollOverCanvas;
            }
        };
        public void onModuleLoad() {
            rollOverCanvas = new HLayout();
            rollOverCanvas.setSnapTo("TR");
            rollOverCanvas.setWidth(40);
            rollOverCanvas.setHeight(22);
            rollOverCanvas.setBackgroundColor("red");
            //removing any of these 3 lines causes no errors in dev mode
            continentField.setFrozen(true);
            countryGrid.setShowRollOverCanvas(true);
            countryGrid.setSelectionAppearance(SelectionAppearance.CHECKBOX);
            
            countryGrid.setWidth(500);
            countryGrid.setHeight(400);
            countryGrid.setFields(continentField, countryNameField);
            countryGrid.setData(getData());
            countryGrid.draw();
        }
        private CountryRecord[] getData() {
            return new CountryRecord[]{
                        new CountryRecord("North America", "United States"),
                        new CountryRecord("Asia", "China"),
                        new CountryRecord("Asia", "Japan"),
                        new CountryRecord("Asia", "India"),
                        new CountryRecord("Europe", "Germany"),
                        new CountryRecord("Europe", "United Kingdom"),
                        new CountryRecord("Europe", "France")};
        }
        private class CountryRecord extends ListGridRecord {
            public CountryRecord(String continent, String countryName) {
                setAttribute("continent", continent);
                setAttribute("countryName", countryName);
            }
        }
    }
    Thanks in advance!

    #2
    This was already fixed on 21 November, two days after the version you're using. You just need to update to the latest patch build - you should always try this if you hit bugs, in case they've already been addressed.

    Comment


      #3
      Thanks for Quick Response. I will update latest patch.

      Comment

      Working...
      X