Announcement

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

    ListGrid.reorderField exception

    Calling reorderField(from,to) on my ListGrid throws a JS exception.

    I am calling reorderField immediately after the DS is bound.

    When manually reordering fields, it works OK.

    This is with latest nightly build.

    Code:
     'com.google.gwt.core.client.JavaScriptException: (TypeError): this.filterEditor is undefined fileName: http://localhost:8888/szolorg/sc/modules/ISC_Grids.js lineNumber: 2227 stack: (3,4,-2)@http://localhost:8888/szolorg/sc/modules/ISC_Grids.js:2227 (3,1)@http://localhost:8888/szolorg/sc/modules/ISC_Grids.js:2226 (3,1)@http://localhost:8888:1589 @:0 ([object GWTJavaObject],17629185,[object XMLHttpRequest])@http://localhost:8888/szolorg/hosted.html?szolorg:56 ([object Event])@http://localhost:8888:4 ((function () {__gwt_makeJavaInvoke(1)(handler, 17629185, _this);}),[object XMLHttpRequest],[object Object])@http://localhost:8888:6 @:0 (null,65563,(function () {__gwt_makeJavaInvoke(1)(handler, 17629185, _this);}),[object XMLHttpRequest],[object Object])@http://localhost:8888/szolorg/hosted.html?szolorg:56 ([object Event])@http://localhost:8888:59
    com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:195)
    com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:120)
    com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:507)
    com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java:284)
    com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java:107) 
    com.smartgwt.client.widgets.grid.ListGrid.reorderField(ListGrid.java)

    #2
    Thanks for bringing this to our attention. The bug is actually that calling reorderFields before the ListGrid has been drawn will fail.
    We've now fixed this internally (fix should hit SVN in the next few days).

    In the meantime, try delaying your call to reorder fields until after the listgrid has been draw()n

    Comment


      #3
      OK, putting the reorderField call into a DrawHandler fixed the problem.
      The same worked for freezeField, too. (See http://forums.smartclient.com/showthread.php?t=9714 for the problem.)

      Comment

      Working...
      X