When I try to invoke an MessageDialog my app crashes with the following error message:
System.Runtime.InteropServices.COMException: 'Invalid Window Identifier. (0x80070578)'
This occurs both on the App.xaml.xs and in an helper I have for that propose.
Code on app.xaml:
var messageDialog = new MessageDialog("Excedeu o limite de tentativas para fazer login.");
var result = await messageDialog.ShowAsync();
Code on helper:
public static async Task ShowAsync(String keyName)
{
var msg = LocalizationHelper.GetValue(keyName);
if (string.IsNullOrWhiteSpace(msg)) msg = keyName;
var messageDialog = new MessageDialog(msg);
await messageDialog.ShowAsync();
}