locked
Open non-metro window from metro application

    Question

  • Hello

    Can I open non-metro window (CreateWindow or CreateWindowEx) from a metro application? The code that opens a window is working perfectly, i ever can see the window in the spy++ utility but not on the screen.  

    What is wrong?

    Thanks in advance,

    Michael

    Wednesday, February 26, 2014 8:57 AM

Answers

  • you won't get it working. its not supported from store apps. here is list with the supprot win32 api's http://msdn.microsoft.com/en-us/library/windows/apps/br205757.aspx


    Microsoft Certified Solutions Developer - Windows Store Apps Using C#

    Wednesday, February 26, 2014 9:07 AM

All replies

  • no this api isnt available for WIndows Store apps so you wont get it in the windows store if you do.

    Microsoft Certified Solutions Developer - Windows Store Apps Using C#

    Wednesday, February 26, 2014 8:58 AM
  • Thank you Dave

    "this api isnt available for WIndows Store apps" - i already did that. my problem is how to do it working (visible)

    The window exists (i can see it with spy++), it has a right properties, size and position. The only problem that i cannot see it

    Wednesday, February 26, 2014 9:03 AM
  • you won't get it working. its not supported from store apps. here is list with the supprot win32 api's http://msdn.microsoft.com/en-us/library/windows/apps/br205757.aspx


    Microsoft Certified Solutions Developer - Windows Store Apps Using C#

    Wednesday, February 26, 2014 9:07 AM
  • Thank you
    Wednesday, February 26, 2014 9:14 AM
  • Windows Store apps have a number of isolation features that improve the security and trustworthiness of arbitrary code. The biggest is the AppContainer context they always run in which puts ACL and integrity level boundaries around all the system APIs to constraint the apps behavior.

    http://blogs.msdn.com/b/ieinternals/archive/2012/03/23/understanding-ie10-enhanced-protected-mode-network-security-addons-cookies-metro-desktop.aspx

    The second is the WACK tool that prevents applications from being published to the Windows Store that call unsupported Win32 APIs.

    http://msdn.microsoft.com/en-us/library/windows/apps/hh694081.aspx

    In other words, you can locally on your development system call many Win32 APIs from a Windows Store app (by either circumventing the PARTITION macros or by explicitly creating function typedefs) that may or may not actually work within the AppContainer context, and in any case you can never publish that app since it would fail WACK.

    Wednesday, February 26, 2014 6:49 PM
  • Thank you Chuck for your explanations
    Thursday, February 27, 2014 9:53 AM