Solved

Show a contextmenu when right-click on a selected node of a lisview.

Posted on 2011-09-29
2
209 Views
Last Modified: 2013-12-17
Dear Experts,

I have set a contextmenu to a listview. But as you can see in the picture
I can right-click anywhere in the listview.

What I would like is to show the contextmenu only when a user right-clicks
on a selected node.

Who knows the answer?

Peter

Peter
Example.jpg
0
Comment
Question by:peterkiers
2 Comments
 
LVL 1

Author Comment

by:peterkiers
ID: 36813476
I do not get further than this:

        private void lvNotes_MouseUp(object sender, MouseEventArgs e)
        {
            if (e.Button == MouseButtons.Right)
            {


            }
        }

P.
0
 
LVL 8

Accepted Solution

by:
jagrut_patel earned 500 total points
ID: 36814208
See this link.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

914 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now