Hello,
I am trying to disable one ListGrid field based on the value selected in another ListGrid field. However, I'm getting exceptions that I'm not sure how to resolve.
I'm getting the following exception when trying to set the disabled property directly on the ListGrid field. It appears to work from a UI perspective but I still see the following exception:
Here is what my method signature looks like on the ListGrid field for the above exception:
And here is the attempt in the updateQuickAddFund function to get a handle to the right field to then set disabled directly on the field instead of calling setDisabled():
The first attempt works but I get that exception. So, I tried to also pass in a form like so:
And, then tried to get a handle to the field like this in order to call setDisabled():
But, that causes the same exact exception but does not disable the other ListGrid field in the UI. Any ideas what I'm doing wrong?
I am trying to disable one ListGrid field based on the value selected in another ListGrid field. However, I'm getting exceptions that I'm not sure how to resolve.
I'm getting the following exception when trying to set the disabled property directly on the ListGrid field. It appears to work from a UI perspective but I still see the following exception:
Code:
11:45:49.439:MUP9:WARN:Log:Error: ''this.form.fieldIdProperty' is null or not an object' in http://localhost:8080/dev/dpt.form at line 635 FormItem.getFieldName() "return this[this.form.fieldIdProperty]" ListGrid.handleEditorChanged(_1=>[SelectItem ID:isc_SelectItem_1646 name:fundID]) [o]SelectItem.handleChanged(_1=>"1", _2=>undef, _3=>undef, _4=>undef) "this.invokeSuper(this.getClassName(),"handleChanged",_1,_2,_3,_4);this.grid.handleEditorChanged(this)" FormItem.$10y(_1=>"1") SelectItem.updateValue() SelectItem.changeToValue(_1=>"1", _2=>true) SelectItem.pickValue(_1=>"1") PickListMenu.itemClick(_1=>Obj) ScrollingMenu.recordClick(_1=>[PickListMenu ID:isc_PickListMenu_1654], _2=>Obj, _3=>0, _4=>Obj{name:fundID}, _5=>0, _6=>"Alpha Fund", _7=>"1") "this.hide();if(_2!=null)this.itemClick(_2)" ListGrid.rowClick(_1=>Obj, _2=>0, _3=>0, _4=>undef) [a]GridBody.rowClick(record=>Obj, rowNum=>0, colNum=>0) "if (this.fields[colNum]) colNum = this.fields[colNum].masterIndex;return this.grid.rowClick(record,rowNum,colNum)" GridRenderer.$29y(_1=>0, _2=>0) GridRenderer.click(Obj, undef) "if(this.$29p())return;var _1=this.getEventRow(),_2=this.getEventColumn();return this.$29y(_1,_2)" Canvas.handleClick(_1=>Obj, _2=>undef) EventHandler.bubbleEvent(_1=>[GridBody ID:isc_PickListMenu_1654_body], _2=>"click", _3=>undef, _4=>undef) EventHandler.handleClick(_1=>[GridBody ID:isc_PickListMenu_1654_body], _2=>undef) EventHandler.$k5(_1=>Obj{type:error}, _2=>undef) EventHandler.handleMouseUp(_1=>Obj{type:error}, _2=>undef) EventHandler.dispatch(_1=>EventHandler.handleMouseUp(), _2=>Obj{type:error}) anonymous(event=>undef) "var returnVal=arguments.callee.$ch.isc.EH.dispatch(arguments.callee.$j2,event);return returnVal;"
Here is what my method signature looks like on the ListGrid field for the above exception:
Code:
changed:"updateQuickAddFund(item,value);"
Code:
var currentSharesField = item.grid.getField(item.grid.getColNum("currentShares")); //now try to set disabled directly currentSharesField.disabled=true
The first attempt works but I get that exception. So, I tried to also pass in a form like so:
Code:
changed:"updateQuickAddFund(form,item,value);"
Code:
var currentSharesField = form.getField("currentShares"); currentSharesField.setDisabled(true);