I created a WPF program that runs in the VIsual studio at startup. I made an installer for my program with Visual Installer Projects 2017. On the one hand, the program worked, and I got the following dialog:
An unhandled Microsoft.NET Framework exception occured in Program1.exe [10204].
My catch block is as follows
Dispatcher.Invoke(new Action(() =>
{
EnableContent();
}));
}
catch (AggregateException e)
{
MessageBox.Show(e.ToString());
Dispatcher.Invoke(new Action(() =>
{
UpdateLoadMsg("No internet connection.", MsgType.FAIL);
}));
}
catch (Exception e)
{
MessageBox.Show(e.ToString());
Dispatcher.Invoke(new Action(() =>
{
UpdateLoadMsg("Something went wrong.", MsgType.FAIL);
}));
}
Messagebox never displays! apparently the exception does not get. I don’t know how to debug this if there is no way to debug it!
Nahro source
share