Carri
Carri

Reputation: 193

WPF: Double Click on Path Event

I have several paths nested inside a canvas. I want each path to display a MessageBox when the user double clicks on the path. I know the path class doesn't have the MouseDoubleClick event, but the canvas class does so maybe that can help.

How do you create a MouseDoubleClick event for a Path?

Upvotes: 1

Views: 4140

Answers (1)

Thomas Li
Thomas Li

Reputation: 3338

The Path class has the MouseDown event. You can detect the number of clicks with the ClickCount property of the MouseButtonEventArgs.

Check http://www.switchonthecode.com/tutorials/wpf-tutorial-getting-the-doubleclick-event for more info.

Upvotes: 5

Related Questions