I have created an image button which does something if double-clicked. I want pressing enter also to do the same thing. How can I do that?
如果是WPF按钮,则执行IsDefault="True"
并安装常规的单击处理程序。
您可以使用KeyDown
事件检查e.Key == Keys.Enter
然后调用双击使用的相同函数。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.