Skip to main content
Home Forums Silverlight Programming Programming with .NET - General Can I handle the Mouse Right Click in Silverlight 2 ?
6 replies. Latest Post by o_programador on November 17, 2008.
(0)
JOUNEY
Member
0 points
3 Posts
11-10-2008 5:22 AM |
There are the next mouse event: MouseMove, MouseLeftButtonUp, MouseLeftButtonDown, MouseLeave, MouseEnter. But what about Mouse Right Click? I want to handle mouse right click. Can I do?
metal
Participant
1243 points
262 Posts
11-10-2008 6:29 AM |
The Deep Zoom auto created projects have a Javascript handler to pass through mouse wheel scrolling events, you ould look at that, but I am guessing the current Right click action of "Silverlight Configuration" can not be over ridden.
pbromberg
Contributor
2128 points
370 Posts
11-10-2008 7:53 AM |
A quick search on Silverlight "right click" reveals this:
http://silverlight.net/blogs/msnow/archive/2008/07/01/tip-of-the-day-14-how-to-right-click-on-a-silverlight-application.aspx
o_progra...
14 points
2 Posts
11-13-2008 12:59 PM |
Yes. And here goes a very simple project demonstrating how to do that at the KYNOU.com web site
http://www.kynou.com/Samples/TestingSilverlightRightClick.zip
11-13-2008 8:46 PM |
Thank you guys~
But Can I use "Silverlight Configuration"?
If I use ContextEvent, How can users auto update Silverlight plug in?
Jonathan...
All-Star
24979 points
2,434 Posts
11-14-2008 4:14 AM |
Hi Jouney,
As far as I know, we can use JavaScript to get the ContextMenu and add "Silverlight Configuration" as an item to the ContextMenu. But we cannot call the Silverlight Configuration Dialogue.
Best regards,
Jonathan
11-17-2008 10:28 AM |
The code that I submitted assumes that you don't want to get the configuration UI (it's the most common case). But if you do want to do your context menu and still let the silverlight configuration window appear just don't use the e.PreventDefault() method you will find in the posted code.
I hope this helps