Since I am new with C#, I am finding it hard to implement using the details in that documentation. I found one link as follows, but that is not usable for UWP. msdn.microsoft.com/en-us/library/… An equivalent of the above documented example will be very helpful for me.
If you create a new blank UWP project, you will find the App.xaml.cs
file. Open it and register the UnhandledException
event for your app like the following:
sealed partial class App : Application
{
/// <summary>
/// Initializes the singleton application object. This is the first line of authored code
/// executed, and as such is the logical equivalent of main() or WinMain().
/// </summary>
public App()
{
this.InitializeComponent();
this.Suspending += OnSuspending;
this.UnhandledException += App_UnhandledException;
}
private void App_UnhandledException(object sender, UnhandledExceptionEventArgs e)
{
//TODO:
}
....
}

Since you said that you're new with c#, what you need to do is to learn some c# basic technology at first. For example, How to: Subscribe to and Unsubscribe from Events (C# Programming Guide)