Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to display a message in Windows Store Apps?

Tags:

c#

windows-8

How to display a message box in windows 8 apps using c# like calling MessageBox.Show() in windows phone 7?

like image 790
user1547566 Avatar asked Sep 15 '12 07:09

user1547566


People also ask

Why can't I download Apps from Microsoft Store?

Make sure Windows has the latest update: Select check for updates now, and then select Check for updates. Or, select the Start button, then select Settings > Update & Security > Windows Update > Check for Updates. If there is an available update, select Install now.

How do I download from Microsoft Store?

Go to the Start button, and then from the apps list select Microsoft Store. Visit the Apps or Games tab in Microsoft Store. To see more of any category, select Show all at the end of the row. Select the app or game you'd like to download, and then select Get.

Where are Microsoft Store Apps installed Windows 10?

Viewing the location of programs and apps downloaded from the Microsoft Store. Programs and apps downloaded from the Microsoft Store are installed in the following path by default: C:/Program Files/WindowsApps (Hidden items). To check hidden items, open This PC, click View and select Hidden items.


2 Answers

   MessageDialog msgDialog = new MessageDialog("Your message", "Your title");     //OK Button    UICommand okBtn = new UICommand("OK");    okBtn.Invoked = OkBtnClick;    msgDialog.Commands.Add(okBtn);     //Cancel Button    UICommand cancelBtn = new UICommand("Cancel");    cancelBtn.Invoked = CancelBtnClick;    msgDialog.Commands.Add(cancelBtn);     //Show message    msgDialog.ShowAsync(); 

And your call backs

private void CancelBtnClick(IUICommand command) { }  private void OkBtnClick(IUICommand command) { } 


P.S. You can follow this tutorial for more.

like image 104
Inder Kumar Rathore Avatar answered Sep 28 '22 22:09

Inder Kumar Rathore


The MessageDialog class should fit your needs.

like image 31
JP Alioto Avatar answered Sep 28 '22 22:09

JP Alioto