Вопрос

I am looking for some help where I can get a menu option on right clicking a row on Janus WinForms Gridex control to trigger some code. Any one has some ideas ?

Basically I want to include options like Edit / Delete / Process on each row's right click menu option. How do we enable this? I have seen in compiled code samples that it is possible.

Это было полезно?

Решение

You can add a ContextMenuStrip on your form and set it up the way you want it. After that, set set property ContextMenuStrip on the GridEX to the ContextMenuStrip you created. That's it.

Другие советы

First, Add a ContextMenuStrip on your form and add the menu item/s you want. Second, set the MouseClick event for the grid,in the event use the following code:

if (e.Button == MouseButtons.Right){ contentMenuStrip.Show(Cursor.Position);}

Finally, set the click event for the menu item and input you code.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top