0

I need to switch between metro apps backwards and forwards. Is there a way to get an array of metro apps or the number of metro apps running?

I am making a desktop app!enter image description here

Mihai Bratulescu
  • 1,915
  • 3
  • 27
  • 43
  • 1
    There is no supported interface for getting this information. – Raymond Chen Dec 28 '13 at 17:24
  • that array has to be stored somewhere – Mihai Bratulescu Dec 28 '13 at 17:27
  • Perhaps, but like I said, there is no supported interface for getting this information. You may have noticed that the list changed between Windows 8 and Windows 8.1 with the introduction of the "Open in new window" feature. If the list had been exposed in Windows 8, then it would not have been possible to add that feature. – Raymond Chen Dec 28 '13 at 17:30
  • 1
    I've found something: "WWAHost.exe is an essential process, it acts as a host for Metro app processes similar to how svchost.exe acts as a host for .dll files." Do you think now there is a way to get the information I need? – Mihai Bratulescu Dec 28 '13 at 17:49
  • 1
    There is no supported interface for getting this information. You are groveling around undocumented unsupported things which may stop working at any time. – Raymond Chen Dec 28 '13 at 18:36

2 Answers2

0

No, your app doesnt know what other apps are running. This is also a security feature and by design.

dixus
  • 478
  • 4
  • 15
  • Well in this case you are able to read all active [processes](http://msdn.microsoft.com/de-de/library/1f3ys1f9(v=vs.110).aspx). – dixus Dec 28 '13 at 09:36
  • that wont work because I cant tell whitch are metro, also some still appear in task manager but not in the left list since 8.1. – Mihai Bratulescu Dec 28 '13 at 09:43
0

If all apps are made by you, you could use URI protocols (Can I open a Windows 8 application with a URL?) to make the apps call each other. But this is not really "switching", it's a protocol activation which starts an app if it's not already running. As far as I know, this is the only way of making one Windows 8 app call another Windows 8 app (except for other (unsuitable) activations such as file activation).

Community
  • 1
  • 1
Sebastian Negraszus
  • 11,915
  • 7
  • 43
  • 70