I can't seem to find a way client side for the webcombo to trigger a funtion when the control loses focus usually this is the blur() or onblur() ... anyone have any ideas... it works for focus
function ddlFocus() { Log("WebCombo1:Focus"); }
var ddl = igcmbo_getComboById("WebCombo1");
ddl.focus = ddlFocus; //this works
I ran into this issue...here's what appears to be working for me....caveats: It's only tested for use with editable combos, and the code is only tested in IE. There's a crossbrowser attachEvent function at http://phrogz.net/JS/AttachEvent_js.txt that may be useful if you need to work in FF or downlevel browsers.
var ctl = igcmbo_getComboById(comboID); if (ctl && ctl.Editable) { var box = ctl.getInputBox(); box.attachEvent("onblur",cboOnBlur); }
Next is the handling function....
function cboOnBlur(oEvent) {//get the id of the event sourcevar srcID = oEvent.srcElement.id;//since the event source is actually the input control, we need to tweak the id to get the reference to the webcombovar cbo = igcmbo_getComboById(srcID.substr(0,srcID.length - 6));
}
If you were thinking of using
cbo.attributes.add("onblur","myfunction(param,param2);")
igcmbo_onblur(oEvent, webComboId)