I am trying to enable/disable some (treeview) context menu items when a user tries to open the menu but I struggle to find documentation showing the actual method/properties to use.
The documentation about OnClientShowing shows this code
but when I try it it blows up and it looks like I should call args.get_menu()...
Any idea where I can find the right documentation please?
I use 2009 Q1
Regards
Eric
The documentation about OnClientShowing shows this code
<script type="text/javascript"> |
function showContextMenu(menu, args) |
{ |
var target = args.get_targetElement(); |
if (target) |
{ |
if (target.value == "") |
args.set_cancel(true); |
else |
menu.get_items().getItem(1).disable(); |
} |
}</script> |
<telerik:RadContextMenu |
ID="RadContextMenu1" runat="server" |
OnClientShowing="showContextMenu"> |
<Items> |
... |
</Items> |
</telerik:RadContextMenu> |
but when I try it it blows up and it looks like I should call args.get_menu()...
Any idea where I can find the right documentation please?
I use 2009 Q1
Regards
Eric