public static async Task <ContentDialogResult> ShowOK(string title) { InfoDialog dlg = new InfoDialog( ); dlg.Title = title; dlg.PrimaryButtonText = ""; dlg.SecondaryButtonText = "确 定"; dlg.IsPrimaryButtonEnabled = false; dlg.IsSecondaryButtonEnabled = true; return(await dlg.ShowAsync( )); }
private async void button_Click(object sender, RoutedEventArgs e) { InfoDialog dia = new InfoDialog( ); ContentDialogResult ret = await dia.ShowAsync( ); }