I need to pass some arguments to the widget watch method So that it can be used in CallBack Function
Current Code:
require(["dijit/form/NumberTextBox"], function (NumberTextBox) {
var txt = new NumberTextBox({}, "text10");
txt.watch("value", function (name, oldValue, value) {
});
});
Desired code:
require(["dijit/form/NumberTextBox"], function (NumberTextBox) {
var txt = new NumberTextBox({}, "text10");
txt.watch("value", function (name, oldValue, value, PanelID) {
alert(PanelID);
},PanelID);
});
Need to induct PanelID in watch function. I have searched the docs but it seems that we cannot pass arguments to Watch function. Is there any way to override the Watch method and make it accept arguments?