MM
Michael Matela
June 11, 2010 01:24 PM UTC
MouseDown is a low-level event. It gets handled by the WPF button class and transformed into a Click event after some logic, such as only firing if both MouseDown and MouseUp are on the same element.
So you should either bind to the Click event or use the Command property. If you need to do something specific on MouseDown which cannot be handled by Click or Command (ex. change the styling), you could use PreviewMouseDown.
ES
EXAPT Systemtechnik GmbH
June 11, 2010 01:36 PM UTC
Ah, thanks Daniel , for explaining :) I just found out a minute ago, that PreviewMouse... Events do the right thing.
--
Christoph