WPF MenuItem hiding (2 replies)

Posted on .NET 247 See other posts from .NET 247
Published on 08 Jan 2010 14:30:38 Indexed on 2010/03/07 23:55 UTC
Read the original article Hit count: 388

Filed under:
Hi, I would like to hide selected MenuItem on Delete key press without closing the menu. My markup is: Menu MenuItem Header "Menu" MenuItem Header "First" KeyDown "MenuItem KeyDown"/ MenuItem Header "Second" KeyDown "MenuItem KeyDown"/ MenuItem Header "Third" KeyDown "MenuItem KeyDown"/ /MenuItem /Menu where event handler is: private void MenuItem KeyDown(object sender, KeyEventArgs e) { if (e.Key...

© .NET 247 or respective owner