Conditions:
-
the custom control is used in XPiNC
-
newValue property is set to false
Manifestation: You can see error "c is null on line..." in status bar
Solution: Change script in onChange event of OK button to:
var d=dijit.byId('#{javascript:compositeData.dialogID}');
var c=document.getElementById("new#{javascript:compositeData.dialogID}");
var f=document.getElementById("#{javascript:getClientId(compositeData.inputBinding)}");
f.value=d.getSelectedValues();
d.hide();
if(c!=null){
if(c.value!="" && c.value!=null){
d.addItem(c.value);
d.sort();
d.refreshList();
c.value="";
}
}