i have the right click on autocad for repeat the last command.
when i launch my prog. --> the prog show a form with a datagridview. I have added a contextMenuStrip in this datagridview.
SO when i launch the prog with the right click (repeat last command) the form show and the contextmenustrip too. (if the mouse is on the datagrid.)
How i can cancel or purge the event mouse right click ?
I am a noob on the event with vb.net.
For some unknown reason I thought your native language was German, but by looking at your profile, It seems your native language is French. My French is much better than my German (but not great).
In any case, I have just recently (just today, or yesterday, depending on the time zone) started to add a ContextMenuStrip to one of my DataGridView controls, and I have not yet arrived at the point where I could see the behavior you suggest, but I also don't understand your question completely.
Maybe it might help if you phrased your question in your own native language, and then put that through a translator (I know google has a translator, and I am almost sure Microsoft has one under the Bing framework)
Either way, I'll bet I post something on this issue tomorrow or Wednesday, after I finish my current effort, which is to add Paste operations to the DataGridview control already in use (And of course I decided that Ctrl-V needs to be handled, but also Right-Click/Paste).
A possibility If something is firing twice using a form control, double click the control on the form and on the right hand side check the "Handles" there may be more than one. I have had to delete the offending ones in the past so there is only on event:
Change "Handles Button1.Click, Button1Click"
to "Handles Button1.Click"
hi. i have looked for this but i don't use this.
anyone have a trick for remove all event mouse click right or left before launch a dialog form ?
I have been sidetracked, fixing a different problem, but I will be back on the issue of setting up Copy/Paste functionality with a DataGridView Control when I get back to work tomorrow.
I will let you know if I can reproduce your problem , and if I can find a way to fix it.
Sorry. I forgot all about getting back to you, but unfortunately I finished my efforts enabling copy paste operations on a DataGridView with a ContextMenuStrip, but I have not been able to reproduce the problem you are seeing.
One reason might be that the command I am firing with a right click (repeat last command) first prompts the user to select a block before it displays the form.
Typing that just now did give me one idea. Is your command method inside the form code? If so, try moving the command method out of the form code and into a different class or module. I'm afraid that's all I've got for suggestions.
ths. but my command create a form. i display this form with .ShowDialog.
But if the mouse is on a datagridview associate with a contextStripMenu then the contextStrip show.
it is annoying for the user but not very painfull
I like to create a proper code for my user.
Access a broad range of knowledge to help get the most out of your products and services.