Quantcast
Channel: SmartClient Forums
Viewing all articles
Browse latest Browse all 4756

FormItem is no longer castable to JavaScriptObject in SGWT 5.0

$
0
0
I'm moving code to SGWT 5.0; the piece below that worked in prev version now in 5.0 gives ClassCastException when casting FormItem to JavaScriptObject:
/*---------------------------------------------*/
FormItem itemSelected = null;
..........................................
itemSelected = getItem("tradeDateQuarter");// list of qtrs select by end user from qtr dropdown

JavaScriptObject val= (JavaScriptObject) itemSelected.getValue(); // boom: CCE
/*---------------------------------------------*/
Even before trying to pick values that causes this, i got warn in SGWT Dev Console:
-----------------------------------
09:57:21.993:XRP2:WARN:ComboBoxItem:isc_CommonComboBox_16[tradeDateQuarterYear]:BAD VALUES: {newValue: "",
filterLocally: undef,
targetField: "value",
fetchingMissingValues: Obj}
09:57:21.994:XRP2:WARN:ComboBoxItem:isc_CommonComboBox_17[tradeDateMonthYear]:BAD VALUES: {newValue: "",
filterLocally: undef,
targetField: "value",
fetchingMissingValues: Obj}
-----------------------------------
Note sure what causes this warning and whether or not this is the issue. CCE shown in SGWT dev console only. Also in Chrome in sup dev mode, 'itemSelected ' is shown with ObjectAUTOIDClass: "CommonSelectItem", not FormItem as one might expect (CommonSelectItem is a subclass of FormItem, so this might not the issue )

Would be greatly appreciate any help/clue/advise

Viewing all articles
Browse latest Browse all 4756

Trending Articles