I'm having issues with my UWP app. The code below works fine so far, my child window is opened correctly, but every time i close the child window i get an exception and my app dies. Any help would be very appreciated. I'm quite new to UWP and vb.net and still learning so please excuse my sloppy code.
Here's my code for calling the Child-Window:
Private Async Sub btnChildWindow_Click(sender As Object, e As RoutedEventArgs)
Dim appWindow As AppWindow
Dim Nframe = New Frame()
appWindow = Await AppWindow.TryCreateAsync
ElementCompositionPreview.SetAppWindowContent(appWindow, Nframe)
Nframe.Navigate(GetType(PageATVerwaltung))
Await appWindow.TryShowAsync
End Sub
Thanks in advance!