Click here to Skip to main content
15,893,663 members
Home / Discussions / C#
   

C#

 
AnswerRe: C# - get data from MySQL DB into DataGridView Pin
Bizcrack26-Jan-10 5:15
Bizcrack26-Jan-10 5:15 
GeneralRe: C# - get data from MySQL DB into DataGridView Pin
Bizcrack27-Jan-10 4:12
Bizcrack27-Jan-10 4:12 
QuestionAttach scrollbar to listview Pin
Eli Nurman24-Jan-10 8:11
Eli Nurman24-Jan-10 8:11 
AnswerRe: Attach scrollbar to listview Pin
DeepakMega25-Jan-10 1:02
DeepakMega25-Jan-10 1:02 
QuestionContext Menu Not Appearing in Correct Location Pin
kodysumter24-Jan-10 8:10
kodysumter24-Jan-10 8:10 
AnswerRe: Context Menu Not Appearing in Correct Location Pin
Som Shekhar24-Jan-10 8:18
Som Shekhar24-Jan-10 8:18 
GeneralRe: Context Menu Not Appearing in Correct Location Pin
kodysumter24-Jan-10 14:08
kodysumter24-Jan-10 14:08 
GeneralRe: Context Menu Not Appearing in Correct Location Pin
Som Shekhar24-Jan-10 18:02
Som Shekhar24-Jan-10 18:02 
Usually, the best method that worked for me so far is:

1. Let windows handle how to select an item. This is automatically done when mousedown is fired.

2. check for any item being selected. if it is selected, show the menu otherwise not.


this is a code snippet which is working.
private void listView1_MouseUp(object sender, MouseEventArgs e)
   {
       if (listView1.SelectedItems.Count > 0)
       {
           contextMenuStrip1.Show(listView1, e.X, e.Y);
       }
   }

GeneralRe: Context Menu Not Appearing in Correct Location Pin
kodysumter25-Jan-10 15:09
kodysumter25-Jan-10 15:09 
GeneralRe: Context Menu Not Appearing in Correct Location Pin
Som Shekhar25-Jan-10 19:20
Som Shekhar25-Jan-10 19:20 
Questioncombobox datasource switch Pin
Erdinc2724-Jan-10 6:18
Erdinc2724-Jan-10 6:18 
AnswerRe: combobox datasource switch Pin
Abhinav S24-Jan-10 6:22
Abhinav S24-Jan-10 6:22 
GeneralRe: combobox datasource switch Pin
Erdinc2725-Jan-10 4:00
Erdinc2725-Jan-10 4:00 
QuestionXmlAttributeAttribute filter by value ? Pin
GoodIntentions24-Jan-10 4:23
GoodIntentions24-Jan-10 4:23 
QuestionTransferring focus from a textbox to a button Pin
gamer112724-Jan-10 2:49
gamer112724-Jan-10 2:49 
AnswerRe: Transferring focus from a textbox to a button Pin
Som Shekhar24-Jan-10 3:06
Som Shekhar24-Jan-10 3:06 
GeneralRe: Transferring focus from a textbox to a button Pin
Rod Kemp24-Jan-10 3:16
Rod Kemp24-Jan-10 3:16 
GeneralRe: Transferring focus from a textbox to a button Pin
Som Shekhar24-Jan-10 3:18
Som Shekhar24-Jan-10 3:18 
GeneralRe: Transferring focus from a textbox to a button [Modified] Pin
Rod Kemp24-Jan-10 3:34
Rod Kemp24-Jan-10 3:34 
AnswerRe: Transferring focus from a textbox to a button Pin
Jimmanuel24-Jan-10 3:16
Jimmanuel24-Jan-10 3:16 
GeneralRe: Transferring focus from a textbox to a button Pin
gamer112724-Jan-10 3:53
gamer112724-Jan-10 3:53 
GeneralRe: Transferring focus from a textbox to a button Pin
Jimmanuel24-Jan-10 4:23
Jimmanuel24-Jan-10 4:23 
GeneralRe: Transferring focus from a textbox to a button Pin
gamer112724-Jan-10 4:34
gamer112724-Jan-10 4:34 
GeneralRe: Transferring focus from a textbox to a button Pin
gamer112724-Jan-10 4:14
gamer112724-Jan-10 4:14 
AnswerRe: Transferring focus from a textbox to a button Pin
gamer112724-Jan-10 4:18
gamer112724-Jan-10 4:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.