btnOk.RaiseEvent(new RoutedEventArgs(Button.ClickEvent)); 转载于:https://www.cnblogs.com/dajianshi/p/4707771.html