Hello,
I'm looking to create a JavaScript object that will accept as an argument a RadGrid. From within the JavaScript object, I want to attach a function within the JavaScript object to an event within the RadGrid. Specifically, I want to attach a function to the OnRowContextMenu.
To demonstrate this conceptually...
.
The "Grid_aob.ClientSettings.ClientEvents.OnRowContextMenu" assignment is a guess at what I could potentially do, but when I review the RadGrid documentation, there is no such capability.
As a comparison, I was looking at the RadMenu and RadContextMenu methods to add an event handler (e.g., menu.add_itemClicked(myItemClickedHandler)), but there is no reference in the documentation to a similar capability for the RadGrid.
Of course, I would try this, but I'm a fair bit off from getting to that point in my system, and I'd appreciate a sanity check before moving on.
Thank you for your assistance.
I'm looking to create a JavaScript object that will accept as an argument a RadGrid. From within the JavaScript object, I want to attach a function within the JavaScript object to an event within the RadGrid. Specifically, I want to attach a function to the OnRowContextMenu.
To demonstrate this conceptually...
MyController = function (KeyID_ast, Grid_aob, ContextMenu_aob) {
var _KeyVal_ain;
Grid_aob.ClientSettings.ClientEvents.OnRowContextMenu = function (sender, args) {
args.get_tableView().selectItem($get(args.get_id()));
ContextMenu_aob.show(args.get_domEvent());
_KeyVal_ain = args.getDataKeyValue(KeyID_ast);
}
}
The "Grid_aob.ClientSettings.ClientEvents.OnRowContextMenu" assignment is a guess at what I could potentially do, but when I review the RadGrid documentation, there is no such capability.
As a comparison, I was looking at the RadMenu and RadContextMenu methods to add an event handler (e.g., menu.add_itemClicked(myItemClickedHandler)), but there is no reference in the documentation to a similar capability for the RadGrid.
Of course, I would try this, but I'm a fair bit off from getting to that point in my system, and I'd appreciate a sanity check before moving on.
Thank you for your assistance.