1
votes

How to minimize Application window programmatically on UWP, as if the user clicked on the minimize button on the app bar?

Let's say in my app user clicked a button to perform some processing, and now there's nothing left to do but wait until it finishes. In that case I would like to minimize my app automatically.

How to do that?

This is for C++ Windows Universal App.

1
There is currently no facility for a UWP app to minimize itself. (What would that even mean on a phone or HoloLens?) - Raymond Chen
On phone that would mean the same thing as user pressing the Home key - going to the main screen. Would be great if MS could add this. I need it mainly for Desktop, but would be cool for Phone too. Classic WinAPI has this functionality, and even Android does. UWP should too. - Esenthel

1 Answers

2
votes

This is not supported today. Programmatic suspension is an item on our backlog that has not been scheduled/prioritized yet.

Please use UserVoice to submit and/or vote on the feature request. This existing item is probably the closest to your ask: https://wpdev.uservoice.com/forums/110705-universal-windows-platform/suggestions/18076333-allow-an-window-to-minimize-programatically

UPDATE
This is now possible, starting with Windows 10 build 1803: Minimize UWP programatically