The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
|
|
Restrict datagrid right click
Posted: 26 Jul 10 6:12 AM
|
I want to restrict the ability to right click on a datagrid and choose Add,Edit etc.. depending on what user is logged in.
How would i access the right click menu function to make it read-only from inside the form script?
Thanks All. |
|
|
|
Re: Restrict datagrid right click
Posted: 26 Jul 10 7:53 AM
|
You can access each item on the Popup Menu on the Grid, so you can do it as follows (as always, index is zero based):
myGrid.PopupMenu.Items(0).Enabled = true myGrid.PopupMenu.Items(1).Enabled = false |
|
|
|
Re: Restrict datagrid right click
Posted: 29 Jul 10 7:38 AM
|
If it is 7.5, you can also do
myGrid.PopupMenu.ShowAdd = true myGrid.PopupMenu.ShowEdit = false
I think that's also available in 7.2 but not sure. |
|
|
| |
|