问题
With this the default is OK. Can I make the default Cancel?
MessageBoxResult result = MessageBox.Show
(message, caption, MessageBoxButton.OKCancel);
回答1:
Use this overload, which allows you to specify the default MessageBoxResult:
MessageBoxResult result = MessageBox.Show
(message, caption, MessageBoxButton.OKCancel,
MessageBoxImage.Information, MessageBoxResult.Cancel);
来源:https://stackoverflow.com/questions/7179900/wpf-messagebox-default-to-cancel