Adding links to ContextMenuStrip

L

Luigi

Hi all,
I have a TreeList (DevExpress) where I'd like to create a context menu.
I've addedd a ContextMenuStrip to my WinForms with this method:

private void contextMenuStrip1_Opening(object sender, CancelEventArgs e)
{
int a = 0;
}

How can I add only an option (a Delete functionality for example) in this
contextMenu?

Thanks in advance.
 
K

kimiraikkonen

Hi all,
I have a TreeList (DevExpress) where I'd like to create a context menu.
I've addedd a ContextMenuStrip to my WinForms with this method:

private void contextMenuStrip1_Opening(object sender, CancelEventArgs e)
        {
            int a = 0;
        }

How can I add only an option (a Delete functionality for example) in this
contextMenu?

Thanks in advance.

If you're meaning of adding menu items into your contextmenustrip at
runtime, check this out:
You can simply use "Add" method:
http://msdn.microsoft.com/en-us/library/ms229626.aspx

HTH,

Onur Güzel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top