MessageBoxes in Windows Phone 8.1

If you want to use MessageBoxes with your Windows Phone 8.1 Applications instead of using MessageBox you’ll need to use MessageDialog.

Make sure to include the following using statement:

using Windows.UI.Popups;

The code to launch a message box is as follows:

MessageDialog msgDialog = new MessageDialog("Works in Windows Phone 8.1");
//launch the dialog
await dialog.ShowAsync();

Hope that helps.