none
Supported API test error in WACK tools for winodws 10 wup app RRS feed

  • Question

  • I developed WUP app after testing WACK tools it given result Supported API test failed. with following message

    •Error Found: The supported APIs test detected the following errors:◦API GetConsoleOutputCP in api-ms-win-core-console-l1-1-0.dll is not supported for this application type. NotNul.dll calls this API. ◦API GetStdHandle in api-ms-win-core-processenvironment-l1-1-0.dll is not supported for this application type. NotNul.dll calls this API.

    I als got following warning in output

    C:\Program Files\MSBuild\Microsoft.NetNative\ARM\ilc\IlcInternals.targets(886,5): warning : Unresolved P/Invoke method 'SetConsoleTextAttribute!api-ms-win-core-console-l2-1-0.dll' in assembly 'System.Console, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' because it is not available in UWP applications. Please either use an another API , or use [DllImport(ExactSpelling=true) to indicate that you understand the implications of using non-UWP application APIs. 1>C:\Program Files\MSBuild\Microsoft.NetNative\ARM\ilc\IlcInternals.targets(886,5): warning : Unresolved P/Invoke method 'GetConsoleScreenBufferInfo!api-ms-win-core-console-l2-1-0.dll' in assembly 'System.Console, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' because it is not available in UWP applications. Please either use an another API , or use [DllImport(ExactSpelling=true) to indicate that you understand the implications of using non-UWP application APIs.

    How to resolve this issue.I am unable to find where i am using this api's in my code.Thank you in advance.

    Monday, February 8, 2016 8:40 AM

Answers

  • Hi Arun_G,

    That was expected, GetConsoleOutputCP only supported in Desktop apps, UWP cannot use this API per documentation. The same for GetConsoleScreenBufferInfo.

    What is your purpose for using these API, perhaps you can tell us, and we found a workaround for your, directly use un-supported API in UWP will definitely not pass WACK.

    --James


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    • Marked as answer by Arun_G Sunday, February 21, 2016 4:48 AM
    Tuesday, February 9, 2016 2:00 AM

All replies

  • Hi Arun_G,

    That was expected, GetConsoleOutputCP only supported in Desktop apps, UWP cannot use this API per documentation. The same for GetConsoleScreenBufferInfo.

    What is your purpose for using these API, perhaps you can tell us, and we found a workaround for your, directly use un-supported API in UWP will definitely not pass WACK.

    --James


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    • Marked as answer by Arun_G Sunday, February 21, 2016 4:48 AM
    Tuesday, February 9, 2016 2:00 AM
  • @James Thankyou we are using dotnetzip library in that it has some dependencies. we resolved the issue by using new features .net 4.5.2 for zipping. 
    Sunday, February 21, 2016 4:50 AM