double click WPF event shortcut for deleting auto generated function and XAML added tags

StackOverflow https://stackoverflow.com/questions/14584978

سؤال

When I double click on my User Control file, system auto generates a UserControl_Loaded function in .cs file and adds loaded tag in XAML as Loaded="UserControl_Loaded" for UserControl element. It also defines an eventHandler to this.Any shortcut in VS to undo this operation quickly?

هل كانت مفيدة؟

المحلول

You can just Undo once in the .xaml.cs and then flip back to the .xaml and Undo once there and you'll be back to the initial state. Quick keyboard sequence is Ctrl-Z, Ctrl-Tab, Ctrl-Z.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top