On 20 Jan 2007 13:21:08 -0800, "coltrane" <(E-Mail Removed)> wrote:
>Can someone direct me to a reference that describes how to create a
>context menu for a selected row in a datagrid? I have come across many
>threads regarding context menus and datagrids but they all seem to be
>how to modify the default behavior. I've gone through a couple of books
>and many threads but none of these seem to discuss creating a context
>menu for a given row. I did come across a thread that allowed me to
>create a menu for the entire grid but that even allows for a context
>menu outside of any rows.
>
>
>thanks for your help
>
>
>john
You might try capturing the row number from the right click and display your
context menu based on something you determine from the row's data or which
column the right click targeted.
Pseudo code:
If the right click is in Column 1
row display a context menu that is appropriate for column 1
else display a context menu that is appropriate for column[n]
.....
Good luck with your project,
Otis Mukinfus
http://www.arltex.com
http://www.tomchilders.com