https://msdn.microsoft.com/library/windows/apps/xaml/dn706236.aspx


安装好Win10 和Vs2015后调试程序提示

Win10开启开发者模式


进入Win10设置--->升级与安全--->开发者无选项(Win10 预览者版10074)

Win10开启开发者模式


解决方法:

    

Use gpedit to enable your device

  1. Open a cmd prompt with administrator privileges.

  2. Run Gpedit.msc.

  3. Go to Local Computer Policy > Computer Configuration > Administrative Templates > Windows Components > App Package Deployment

  4. Edit the policies to enable the following:

  • Allow all trusted apps to install (Enables your device for sideloading apps)

  • Allows development of Windows Store apps and installing them from an integrated development environment (IDE) (Enables your device for development from Visual Studio)

Reboot your machine.

Win10开启开发者模式Use regedit to enable your device

  1. Open a cmd prompt with administrator privileges.

  2. Run regedit.

  3. Set the value of this DWORD to 1:HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\AppModelUnlock\AllowAllTrustedApps

  4. Set the value of this DWORD to 1:HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\AppModelUnlock\AllowDevelopmentWithoutDevLicense

Win10开启开发者模式Use PowerShell to enable your device

  1. Run Windows PowerShell with administrator privileges.

  2. Run the following command: PS C:\WINDOWS\system32> reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\AppModelUnlock" /t REG_DWORD /f /v "AllowDevelopmentWithoutDevLicense" /d "1"

  3. Run this command too: PS C:\WINDOWS\system32> reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\AppModelUnlock" /t REG_DWORD /f /v "AllowAllTrustedApps" /d "1"