Announcement

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

    Multiple MultiComboBoxItem on same DynamicForm causes TypeError: _1 is null

    SmartGwt 3.1d - latest nightly.
    FireFox 15 - developer

    If there multiple MultiComboBoxItem are located inside DynamicForm then during form creation this log is shown:


    Code:
    17:30:57.646 [ERROR]17:30:57.648:MOU4:WARN:Log:'undefined' is not a valid JavaScript identifier. DataSource and DataBoundComponent field names are required to be valid JavaScript identifiers, the syntax for which is specified by ECMA-262 Section 7.6. Note: The String.isValidID(string) function can be used to test whether a string is a valid identifier. This will be the last warning.

    After form is show and after adding items into second MultiComboBoxItem following error is shown:

    Code:
    Stack from error.stack:
        unnamed(isc_MultiComboBoxItem_sortOrde) @ hwstool/sc/modules/ISC_Forms.js:3048
        unnamed() @ hwstool/sc/modules/ISC_Forms.js:3060
        unnamed(isc_c_MultiComboBoxItem__binarySearc) @ hwstool/sc/modules/ISC_Forms.js:3037
        unnamed(isc_MultiComboBoxItem_updateValueMa) @ hwstool/sc/modules/ISC_Forms.js:3073
        unnamed(isc_FormItem_updateDisplayValueMa) @ hwstool/sc/modules/ISC_Forms.js:1436
        unnamed(isc_MultiComboBoxItem__comboBoxItemChange) @ hwstool/sc/modules/ISC_Forms.js:3054
        unnamed() @ hwstool/sc/modules/ISC_Forms.js:3091
        unnamed(isc_FormItem_handleChange) @ hwstool/sc/modules/ISC_Forms.js:1491
        unnamed(isc_c_Class_invokeSupe) @ hwstool/sc/modules/ISC_Core.js:300
        unnamed(isc_c_Class_Supe) @ hwstool/sc/modules/ISC_Core.js:291
        unnamed(isc_ComboBoxItem_handleChange) @ hwstool/sc/modules/ISC_Forms.js:2966
        unnamed(isc_FormItem_storeValu) @ hwstool/sc/modules/ISC_Forms.js:1489
        unnamed(isc_FormItem__updateValu) @ hwstool/sc/modules/ISC_Forms.js:1486
        unnamed(isc_c_Class_invokeSupe) @ hwstool/sc/modules/ISC_Core.js:300
        unnamed(isc_c_Class_Supe) @ hwstool/sc/modules/ISC_Core.js:291
        unnamed(isc_ComboBoxItem__updateValu) @ hwstool/sc/modules/ISC_Forms.js:2964
        unnamed(isc_FormItem_updateValu) @ hwstool/sc/modules/ISC_Forms.js:1484
        unnamed(isc_ComboBoxItem_pickValu) @ hwstool/sc/modules/ISC_Forms.js:2997
        unnamed(isc_PickListMenu_itemClic) @ hwstool/sc/modules/ISC_Forms.js:2287
        unnamed(isc_PickListMenu_recordClic) @ hwstool/sc/modules/ISC_Forms.js:2282
        unnamed(isc_ListGrid_rowClic) @ hwstool/sc/modules/ISC_Grids.js:1888
        unnamed(anonymou) @ hwstool/sc/modules/ISC_Grids.js:1072
        unnamed(isc_GridRenderer__rowClic) @ hwstool/sc/modules/ISC_Grids.js:852
        unnamed(isc_c_Class_invokeSupe) @ hwstool/sc/modules/ISC_Core.js:300
        unnamed(isc_c_Class_Supe) @ hwstool/sc/modules/ISC_Core.js:291
        unnamed(isc_GridBody__rowClic) @ hwstool/sc/modules/ISC_Grids.js:931
        unnamed(isc_GridRenderer_clic) @ hwstool/sc/modules/ISC_Grids.js:849
        unnamed(isc_Canvas_handleClic) @ hwstool/sc/modules/ISC_Core.js:3464
        unnamed(isc_c_EventHandler_bubbleEven) @ hwstool/sc/modules/ISC_Core.js:1849
        unnamed(isc_c_EventHandler_handleClic) @ hwstool/sc/modules/ISC_Core.js:1677
        unnamed(isc_c_EventHandler__handleMouseU) @ hwstool/sc/modules/ISC_Core.js:1663
        unnamed(isc_c_EventHandler_handleMouseU) @ hwstool/sc/modules/ISC_Core.js:1654
        unnamed(isc_c_EventHandler_dispatc) @ hwstool/sc/modules/ISC_Core.js:1911
        unnamed(anonymou) @ hwstool/sc/modules/ISC_Core.js:40
        unnamed() @ 
    com.smartgwt.client.core.JsObject$SGWT_WARN: 17:31:40.093:IFCS7:WARN:Log:TypeError: _1 is null
    Stack from error.stack:
        unnamed(isc_MultiComboBoxItem_sortOrde) @ hwstool/sc/modules/ISC_Forms.js:3048
        unnamed() @ hwstool/sc/modules/ISC_Forms.js:3060
        unnamed(isc_c_MultiComboBoxItem__binarySearc) @ hwstool/sc/modules/ISC_Forms.js:3037
        unnamed(isc_MultiComboBoxItem_updateValueMa) @ hwstool/sc/modules/ISC_Forms.js:3073
        unnamed(isc_FormItem_updateDisplayValueMa) @ hwstool/sc/modules/ISC_Forms.js:1436
        unnamed(isc_MultiComboBoxItem__comboBoxItemChange) @ hwstool/sc/modules/ISC_Forms.js:3054
        unnamed() @ hwstool/sc/modules/ISC_Forms.js:3091
        unnamed(isc_FormItem_handleChange) @ hwstool/sc/modules/ISC_Forms.js:1491
        unnamed(isc_c_Class_invokeSupe) @ hwstool/sc/modules/ISC_Core.js:300
        unnamed(isc_c_Class_Supe) @ hwstool/sc/modules/ISC_Core.js:291
        unnamed(isc_ComboBoxItem_handleChange) @ hwstool/sc/modules/ISC_Forms.js:2966
        unnamed(isc_FormItem_storeValu) @ hwstool/sc/modules/ISC_Forms.js:1489
        unnamed(isc_FormItem__updateValu) @ hwstool/sc/modules/ISC_Forms.js:1486
        unnamed(isc_c_Class_invokeSupe) @ hwstool/sc/modules/ISC_Core.js:300
        unnamed(isc_c_Class_Supe) @ hwstool/sc/modules/ISC_Core.js:291
        unnamed(isc_ComboBoxItem__updateValu) @ hwstool/sc/modules/ISC_Forms.js:2964
        unnamed(isc_FormItem_updateValu) @ hwstool/sc/modules/ISC_Forms.js:1484
        unnamed(isc_ComboBoxItem_pickValu) @ hwstool/sc/modules/ISC_Forms.js:2997
        unnamed(isc_PickListMenu_itemClic) @ hwstool/sc/modules/ISC_Forms.js:2287
        unnamed(isc_PickListMenu_recordClic) @ hwstool/sc/modules/ISC_Forms.js:2282
        unnamed(isc_ListGrid_rowClic) @ hwstool/sc/modules/ISC_Grids.js:1888
        unnamed(anonymou) @ hwstool/sc/modules/ISC_Grids.js:1072
        unnamed(isc_GridRenderer__rowClic) @ hwstool/sc/modules/ISC_Grids.js:852
        unnamed(isc_c_Class_invokeSupe) @ hwstool/sc/modules/ISC_Core.js:300
        unnamed(isc_c_Class_Supe) @ hwstool/sc/modules/ISC_Core.js:291
        unnamed(isc_GridBody__rowClic) @ hwstool/sc/modules/ISC_Grids.js:931
        unnamed(isc_GridRenderer_clic) @ hwstool/sc/modules/ISC_Grids.js:849
        unnamed(isc_Canvas_handleClic) @ hwstool/sc/modules/ISC_Core.js:3464
        unnamed(isc_c_EventHandler_bubbleEven) @ hwstool/sc/modules/ISC_Core.js:1849
        unnamed(isc_c_EventHandler_handleClic) @ hwstool/sc/modules/ISC_Core.js:1677
        unnamed(isc_c_EventHandler__handleMouseU) @ hwstool/sc/modules/ISC_Core.js:1663
        unnamed(isc_c_EventHandler_handleMouseU) @ hwstool/sc/modules/ISC_Core.js:1654
        unnamed(isc_c_EventHandler_dispatc) @ hwstool/sc/modules/ISC_Core.js:1911
        unnamed(anonymou) @ hwstool/sc/modules/ISC_Core.js:40
        unnamed() @
    Any advice?
    Thank you.
    BR
    Marije

    #2
    These results suggest one of your MultiComboBoxItems does not have a "name" assigned. This is required.

    Comment


      #3
      Thank you for quick reply.

      That is not the case.

      I have checked, all items are created with different name:
      MultiComboBoxItem field = new MultiComboBoxItem(
      "some_name");
      This log of :'undefined' is not a valid JavaScript identifier. is happening when DynamicForm is created and it contains MultiComboBoxItems.

      BR

      Marije

      Comment


        #4
        You can find in attachemnt stand alone test case (which is your show case example) which produces same error logs:
        (Nightly SmartGwt3.1d (/builds/SmartGWT/3.1d/LGPL/2012-09-22))
        Code:
        09:32:54.296 [ERROR] [smartgwttest] 09:32:54.290:WARN:Log:'undefined' is not a valid JavaScript identifier. DataSource and DataBoundComponent field names are required to be valid JavaScript identifiers, the syntax for which is specified by ECMA-262 Section 7.6. Note: The String.isValidID(string) function can be used to test whether a string is a valid identifier. This will be the last warning.
        com.smartgwt.client.core.JsObject$SGWT_WARN: 09:32:54.290:WARN:Log:'undefined' is not a valid JavaScript identifier. DataSource and DataBoundComponent field names are required to be valid JavaScript identifiers, the syntax for which is specified by ECMA-262 Section 7.6. Note: The String.isValidID(string) function can be used to test whether a string is a valid identifier. This will be the last warning.
        Code:
        09:33:07.275 [ERROR] [smartgwttest] 09:33:07.277:IFCS3:WARN:Log:TypeError: _1 is null
        Stack from error.stack:
            unnamed(isc_MultiComboBoxItem_sortOrde) @ smartgwttest/sc/modules/ISC_Forms.js:3048
            unnamed() @ smartgwttest/sc/modules/ISC_Forms.js:3060
            unnamed(isc_c_MultiComboBoxItem__binarySearc) @ smartgwttest/sc/modules/ISC_Forms.js:3037
            unnamed(isc_MultiComboBoxItem__insertButtonForValu) @ smartgwttest/sc/modules/ISC_Forms.js:3061
            unnamed(isc_MultiComboBoxItem__comboBoxItemChange) @ smartgwttest/sc/modules/ISC_Forms.js:3055
            unnamed() @ smartgwttest/sc/modules/ISC_Forms.js:3091
            unnamed(isc_FormItem_handleChange) @ smartgwttest/sc/modules/ISC_Forms.js:1491
            unnamed(isc_c_Class_invokeSupe) @ smartgwttest/sc/modules/ISC_Core.js:300
            unnamed(isc_c_Class_Supe) @ smartgwttest/sc/modules/ISC_Core.js:291
            unnamed(isc_ComboBoxItem_handleChange) @ smartgwttest/sc/modules/ISC_Forms.js:2966
            unnamed(isc_FormItem_storeValu) @ smartgwttest/sc/modules/ISC_Forms.js:1489
            unnamed(isc_FormItem__updateValu) @ smartgwttest/sc/modules/ISC_Forms.js:1486
            unnamed(isc_c_Class_invokeSupe) @ smartgwttest/sc/modules/ISC_Core.js:300
            unnamed(isc_c_Class_Supe) @ smartgwttest/sc/modules/ISC_Core.js:291
            unnamed(isc_ComboBoxItem__updateValu) @ smartgwttest/sc/modules/ISC_Forms.js:2964
            unnamed(isc_FormItem_updateValu) @ smartgwttest/sc/modules/ISC_Forms.js:1484
            unnamed(isc_ComboBoxItem_pickValu) @ smartgwttest/sc/modules/ISC_Forms.js:2997
            unnamed(isc_PickListMenu_itemClic) @ smartgwttest/sc/modules/ISC_Forms.js:2287
            unnamed(isc_PickListMenu_recordClic) @ smartgwttest/sc/modules/ISC_Forms.js:2282
            unnamed(isc_ListGrid_rowClic) @ smartgwttest/sc/modules/ISC_Grids.js:1888
            unnamed(anonymou) @ smartgwttest/sc/modules/ISC_Grids.js:1072
            unnamed(isc_GridRenderer__rowClic) @ smartgwttest/sc/modules/ISC_Grids.js:852
            unnamed(isc_c_Class_invokeSupe) @ smartgwttest/sc/modules/ISC_Core.js:300
            unnamed(isc_c_Class_Supe) @ smartgwttest/sc/modules/ISC_Core.js:291
            unnamed(isc_GridBody__rowClic) @ smartgwttest/sc/modules/ISC_Grids.js:931
            unnamed(isc_GridRenderer_clic) @ smartgwttest/sc/modules/ISC_Grids.js:849
            unnamed(isc_Canvas_handleClic) @ smartgwttest/sc/modules/ISC_Core.js:3464
            unnamed(isc_c_EventHandler_bubbleEven) @ smartgwttest/sc/modules/ISC_Core.js:1849
            unnamed(isc_c_EventHandler_handleClic) @ smartgwttest/sc/modules/ISC_Core.js:1677
            unnamed(isc_c_EventHandler__handleMouseU) @ smartgwttest/sc/modules/ISC_Core.js:1663
            unnamed(isc_c_EventHandler_handleMouseU) @ smartgwttest/sc/modules/ISC_Core.js:1654
            unnamed(isc_c_EventHandler_dispatc) @ smartgwttest/sc/modules/ISC_Core.js:1911
            unnamed(anonymou) @ smartgwttest/sc/modules/ISC_Core.js:40
            unnamed() @ 
        com.smartgwt.client.core.JsObject$SGWT_WARN: 09:33:07.277:IFCS3:WARN:Log:TypeError: _1 is null
        Stack from error.stack:
            unnamed(isc_MultiComboBoxItem_sortOrde) @ smartgwttest/sc/modules/ISC_Forms.js:3048
            unnamed() @ smartgwttest/sc/modules/ISC_Forms.js:3060
            unnamed(isc_c_MultiComboBoxItem__binarySearc) @ smartgwttest/sc/modules/ISC_Forms.js:3037
            unnamed(isc_MultiComboBoxItem__insertButtonForValu) @ smartgwttest/sc/modules/ISC_Forms.js:3061
            unnamed(isc_MultiComboBoxItem__comboBoxItemChange) @ smartgwttest/sc/modules/ISC_Forms.js:3055
            unnamed() @ smartgwttest/sc/modules/ISC_Forms.js:3091
            unnamed(isc_FormItem_handleChange) @ smartgwttest/sc/modules/ISC_Forms.js:1491
            unnamed(isc_c_Class_invokeSupe) @ smartgwttest/sc/modules/ISC_Core.js:300
            unnamed(isc_c_Class_Supe) @ smartgwttest/sc/modules/ISC_Core.js:291
            unnamed(isc_ComboBoxItem_handleChange) @ smartgwttest/sc/modules/ISC_Forms.js:2966
            unnamed(isc_FormItem_storeValu) @ smartgwttest/sc/modules/ISC_Forms.js:1489
            unnamed(isc_FormItem__updateValu) @ smartgwttest/sc/modules/ISC_Forms.js:1486
            unnamed(isc_c_Class_invokeSupe) @ smartgwttest/sc/modules/ISC_Core.js:300
            unnamed(isc_c_Class_Supe) @ smartgwttest/sc/modules/ISC_Core.js:291
            unnamed(isc_ComboBoxItem__updateValu) @ smartgwttest/sc/modules/ISC_Forms.js:2964
            unnamed(isc_FormItem_updateValu) @ smartgwttest/sc/modules/ISC_Forms.js:1484
            unnamed(isc_ComboBoxItem_pickValu) @ smartgwttest/sc/modules/ISC_Forms.js:2997
            unnamed(isc_PickListMenu_itemClic) @ smartgwttest/sc/modules/ISC_Forms.js:2287
            unnamed(isc_PickListMenu_recordClic) @ smartgwttest/sc/modules/ISC_Forms.js:2282
            unnamed(isc_ListGrid_rowClic) @ smartgwttest/sc/modules/ISC_Grids.js:1888
            unnamed(anonymou) @ smartgwttest/sc/modules/ISC_Grids.js:1072
            unnamed(isc_GridRenderer__rowClic) @ smartgwttest/sc/modules/ISC_Grids.js:852
            unnamed(isc_c_Class_invokeSupe) @ smartgwttest/sc/modules/ISC_Core.js:300
            unnamed(isc_c_Class_Supe) @ smartgwttest/sc/modules/ISC_Core.js:291
            unnamed(isc_GridBody__rowClic) @ smartgwttest/sc/modules/ISC_Grids.js:931
            unnamed(isc_GridRenderer_clic) @ smartgwttest/sc/modules/ISC_Grids.js:849
            unnamed(isc_Canvas_handleClic) @ smartgwttest/sc/modules/ISC_Core.js:3464
            unnamed(isc_c_EventHandler_bubbleEven) @ smartgwttest/sc/modules/ISC_Core.js:1849
            unnamed(isc_c_EventHandler_handleClic) @ smartgwttest/sc/modules/ISC_Core.js:1677
            unnamed(isc_c_EventHandler__handleMouseU) @ smartgwttest/sc/modules/ISC_Core.js:1663
            unnamed(isc_c_EventHandler_handleMouseU) @ smartgwttest/sc/modules/ISC_Core.js:1654
            unnamed(isc_c_EventHandler_dispatc) @ smartgwttest/sc/modules/ISC_Core.js:1911
            unnamed(anonymou) @ smartgwttest/sc/modules/ISC_Core.js:40
            unnamed() @
        To reproduce error:
        1. In 'Items' multicombobox add few items.
        2. In 'Employees To Attend' add item. In that moment you will get error.

        Hope this helps.
        Thanks.
        BR
        Marije
        Attached Files

        Comment


          #5
          Thanks for the test case, this has been fixed.

          Comment


            #6
            Thank you for fix, it is working.
            But you still have this warning log:

            Code:
            10:58:00.072 [ERROR] [smartgwttest] 10:58:00.073:WARN:Log:'undefined' is not a valid JavaScript identifier. DataSource and DataBoundComponent field names are required to be valid JavaScript identifiers, the syntax for which is specified by ECMA-262 Section 7.6. Note: The String.isValidID(string) function can be used to test whether a string is a valid identifier. This will be the last warning.
            com.smartgwt.client.core.JsObject$SGWT_WARN: 10:58:00.073:WARN:Log:'undefined' is not a valid JavaScript identifier. DataSource and DataBoundComponent field names are required to be valid JavaScript identifiers, the syntax for which is specified by ECMA-262 Section 7.6. Note: The String.isValidID(string) function can be used to test whether a string is a valid identifier. This will be the last warning.
                at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
                at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
                at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
                at java.lang.reflect.Constructor.newInstance(Unknown Source)
                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.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:337)
                at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:218)
                at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
                at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561)
                at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:269)
                at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:91)
                at com.smartgwt.client.widgets.form.DynamicForm.create(DynamicForm.java)
                at com.smartgwt.client.widgets.BaseWidget.getOrCreateJsObj(BaseWidget.java:386)
                at com.test.client.SmartGwtTest.onModuleLoad(SmartGwtTest.java:85)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
                at java.lang.reflect.Method.invoke(Unknown Source)
                at com.google.gwt.dev.shell.ModuleSpace.onLoad(ModuleSpace.java:396)
                at com.google.gwt.dev.shell.OophmSessionHandler.loadModule(OophmSessionHandler.java:200)
                at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:525)
                at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:363)
                at java.lang.Thread.run(Unknown Source)
            Thank you.
            BR
            Marije

            Comment


              #7
              This spurious warning has now been fixed.

              Note there's a problem in your code - setValueMap() should be called on the MultiComboBoxItem itself, not via the comboBoxProperties setter.

              Comment

              Working...
              X