application.shutdown

  1. S

    How to execute a method from Application.Shutdown

    I want to run a method in the MainWindowViewModel (I want to make sure some Com Ports are closed before the app closes). In the App.XAML I added Exit = "ExitEventHandler." I want the MainWindowViewModel to watch for this event and run the method to close the ports. I am not getting the setup...
Back
Top Bottom