Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Metro App can no longer be programmatically killed?

I'm new to Win 8 Metro application development, and discovered that lots of things seem to be changed from the classic WPF.

What troubles me the most is that there's no way to close the app. This is extremely annoying when it comes to debugging the app. Therefore I'm looking at ways to add a "close" button in my app.

However, the old WPF way of:

Application.Current.Shutdown() 

no longer exists. And I couldn't find the Process class in System.Diagnostics any more.

Does anyone know how to do this?

like image 796
Daqi Pei Avatar asked Jan 27 '12 02:01

Daqi Pei


1 Answers

You're looking for App.Current.Exit()

like image 65
Robert Levy Avatar answered Sep 22 '22 12:09

Robert Levy