简体   繁体   English

缺少适用于 UWP 的 Windows 桌面扩展 SDK

[英]Missing Windows Desktop Extension SDK for UWP

I try to repeat this manual .我尝试重复本手册 My project is blank WPF + blank UWP app.我的项目是空白的 WPF + 空白的 UWP 应用程序。

  • Target ver.目标版本Windows 10 (1903), 10.0 Build 18362 Windows 10 (1903), 10.0 内部版本 18362
  • Min ver.最小版本。 Windows 10 (1903), 10.0; Windows 10 (1903), 10.0; Build 17763构建 17763

I have installed SDK Windows 10 (10.0.18362.0) screenshot我已经安装了 SDK Windows 10 (10.0.18362.0)截图

I don't have references Windows Desktop Extension SDK for UWP .我没有参考Windows Desktop Extension SDK for UWP screenshot截屏

What is wrong?怎么了? How to add Windows Desktop Extension SDK for UWP to my project?如何将适用于 UWP 的 Windows 桌面扩展 SDK 添加到我的项目中?

I tried install all version SDK from 16299 to 18362, reinstalled and repaired the vs studio.我尝试安装从 16299 到 18362 的所有版本 SDK,重新安装并修复了 vs studio。 Manual installed Windows 10 SDK from microsoft it also did not help.从微软手动安装 Windows 10 SDK 它也没有帮助。 I foundinformation that Windows Desktop Extension SDK for UWP was merged to main UWP packet.我发现有关UWP 的 Windows 桌面扩展 SDK 已合并到主 UWP 数据包的信息。

But when i try run the project without Windows Desktop Extension SDK i get error但是当我尝试在没有 Windows 桌面扩展 SDK 的情况下运行项目时,我收到错误

Error CS0103 The name 'FullTrustProcessLauncher' does not exist in the current context .错误 CS0103 当前上下文中不存在名称“FullTrustProcessLauncher”

        if (ApiInformation.IsApiContractPresent("Windows.ApplicationModel.FullTrustAppContract", 1, 0))
        {
            await FullTrustProcessLauncher.LaunchFullTrustProcessForCurrentAppAsync();
        }

I have the same error when i try to run github example from manul without Windows Desktop Extension SDK当我尝试从没有 Windows 桌面扩展 SDK 的 manul 运行 github 示例时遇到同样的错误

Solution found.找到解决方案。

For random reason your Windows SDK can be installed to wrong directory.由于随机原因,您的 Windows SDK 可能安装到错误的目录。 For me it is C:\\Program Files (x86)\\Microsoft Platform SDK .对我来说是C:\\Program Files (x86)\\Microsoft Platform SDK Right path is C:\\Program Files (x86)\\Windows Kits\\10 I just made symbol link正确的路径是C:\\Program Files (x86)\\Windows Kits\\10我刚刚做了符号链接

mklink /j “C:\Program Files (x86)\Windows Kits\10” “C:\Program Files (x86)\Microsoft Platform SDK”

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM