Windows SDK UWP Application Error - DEP3321

I fought DEP3321: To deploy this application, the deployment target must run with Windows Universal Runtime version 10.0.14393.0 or higher. You are currently using version 10.0.10586.839. Upgrade your OS or change your deployment target to a device with the correct version. over the past few days.

I have a UWP app that I cannot run on my machine. However, if I choose one of the emulators, it works fine. I also set a minimum target value which makes sure the app is running, however the app throws an error as it can't find some methods in the lower SDK version.

I tried to repair and uninstall / reinstall visual studio 2015 and 2017. I have tried the same with various Windows SDKs. At one point, I had three versions of the SDK and visual studio was still complaining even though I had an updated version. I have currently installed win sdk 10.0.15063.17.

Any ideas what I can do to fix this problem. I've spent various SO pages as well as social.msdn pages with no luck.

Many thanks

+7


source to share


4 answers


I just launched a new application, selected the highest target levels and got this error. I managed to get rid of this error by choosing the default minimum minimum target version as shown below.Change UWP Properties



+6


source


If your application uses APIs that only exist on newer OS versions (for example, 14393 or 15063), you will not be able to call them on 10586. You will get an exception because the method simply does not exist on that machine.

To support your application on lower versions of the operating system, you will need to wrap your calls with these APIs with the appropriate "IsAPIPresent" check:



https://docs.microsoft.com/en-us/uwp/api/Windows.Foundation.Metadata.ApiInformation

Thank you Stefan Wick - Windows Developer Platform

+2


source


Possible solution: I faced the EXACT same problem. I have SDK 15063 and I installed Visual Studio 2017 again, which also implicitly installed SDK 15063, but I still kept getting the same DEP3321 deployment error.

I solved this problem this way - Just go to "Solution Explorer" on the right side of Visual Studio and follow these steps in this order -

1) Just right click on the project you are deploying

2) Click "Unload Project"

3) Right click on project_name (not available) and click Edit project_name.jsproj. It will open the xml file from the left side

4) Find "TargetPlatformVersion" and "TargetPlatformMinVersion". Both are located next to each other. Mine looked like this: 10.0.15063.0 10.0.15063.0 since my DEP3321 error explicitly stated "you are currently using version 10.0.14393.1715, so I replaced" TargetPlatformMinVersion "from 10.0.15063.0 to 10.0.14393.1715 - 10.0.14393.1715

5) Now save it, Ctrl + S

6) Right-click on Solution Explorer and click Update Project and click Yes in the pop-up window if you declare that the project is already loaded.

You are done. Just do what you normally do, Build (ctrl + shift + B) and then Debug - F5 or Ctrl + F5. So the project was deployed for me.

0


source


I also faced the same problem

Severity Code Description Project File Line Suppression Status Error DEP3321: To deploy this application, the deployment target must be running Windows Universal Runtime version 10.0.17763.0 or higher. You are currently using version 10.0.17134.648. Please upgrade your OS or change the deployment target to a device with the correct version.

Solution: Right click on the project property and go to General-> Target Platform Minimum. In my case, I changed it to "10.0.17134.0" by selecting from the dropdown and then rebuilding it. I worked well. Attached picture for reference.enter image description here

0


source







All Articles