HoloLens/Unity - Missing Debug framework Error DEP8000 - c#

I'm running Unity 2018.1.7f1 on Windows 10 Insider Preview 10.0.17711, and suddenly I can't deploy a debug version of my app to HoloLens. It seems to be an issue either with the latest OS preview, or the new version of Unity.
Error DEP8000 : Unexpected deployment failure : RemoteCommandException
: Windows cannot install package Template3D_1.0.0.0_x86__pzq3xp76mxafg
because this package depends on a framework that could not be found.
Provide the framework "Microsoft.VCLibs.140.00.Debug" published by
"CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond,
S=Washington, C=US", with neutral or x86 processor architecture and
minimum version 14.0.26428.1, along with this package to install. The
frameworks with name "Microsoft.VCLibs.140.00.Debug" currently
installed are:
{Microsoft.VCLibs.140.00.Debug_14.0.26128.0_x86__8wekyb3d8bbwe}
I have the latest VS2017 installed all the Windows SDKs installed up to the current 10.0.17134.0, and the latest HoloLens emulator/VS2017 templates. I've tried adding the missing framework using PowerShell (Add-AppxPackage). Stumped.

The answer is here:
https://www.microsoft.com/en-gb/download/details.aspx?id=30135 - Microsoft .NET Framework Repair Tool. It immediately found and fixed the issue.

I had same issue. Then I remembered that even in Microsoft's tutorial release version is used instead of debug.
I'm referring to following text:
Using the top toolbar in Visual Studio, change the target from Debug to Release and from ARM to X86.
You can find same instruction in both tutorials:
MR Basics 101
MR Basics 101E
Now I realize that this doesn't solves your issue directly because you will be deploying release version and not debug one but I guess that there might be others stumbling upon this issue so this way you can at least continue developing, and if Microsoft doesn't use debug version than just maybe it isn't meant to be used.

Related

MSBuild fails for .NET Core SDK Version 2.2.202

After downloading and installing Visual Studio 2019 RC, I cannot run msbuild, and get the following error:
"Version 2.2.202 of the .NET Core SDK requires at least version 16.0.0 of MSBuild.
The current available version of MSBuild is 15.6.82.30579.
Change the .NET Core SDK specified in global.json to an older version that requires the MSBuild version currently available."
I cannot find MSBuild version 16. The only version I find is this one here:
"C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0"
.NET Core SDK versions 2.2.2XX and 2.1.6XX are intended to be used with Visual Studio 2019 and MSBuild 16.x.
.NET Core SDK versions for Visual Studio 2017 are 2.2.1XX and 2.1.5XX.
See this GitHub issue for more details.
Updating Visual Studio to the minimum supported version or above should fix this problem.
Some .NET Core versions also include fixes in MSBuild. They are distributed together with Visual Studio.
They put the minimum supported versions in the release notes of .NET Core.
For example: Announcing .NET Core 2.2 | .NET Blog
For people coming here because they have the in Azure DevOps Pipelines - here some pointers for that.
If you have a private agent pool configured (e.g. private build machine), you might want to update your machine to support a more recent MSBuild version. See other answers.
If you don't have configured a build agent and use a default agent pool provided by Azure DevOps itself (e.g. "Hosted" or VS2019), see if there is a newer Hosted one that supports your configuration. See screenshot below where to look.
I ran into this with our on-prem build server we use with GitHub Actions.
The solution was to run Visual Studio Installer and update Visual Studio Build Tools 2017 and 2019.
I realize this solution is very similiar to those above, but I wanted to speak to the situations where Visual Studio is not installed, but Build Tools are.
For anyone that is still coming across this issue. I found another way, to get around this without upgrading to VS 2019 or rolling back SDK 3.1. My experience is in TFS 2017 (on-prem). I'm the build engineer, not a developer.
I had an SDK 2.2 app that was failing after the install of 3.1.
Initially, it was causing the NuGet steps to fail. Research led to me asking the developers to add a global.json file having it point to 2.2. This fixed the NuGet errors.
Then MSBuild step was failing with similar to OPs message. Couldn't figure out why 3.1 was taking presedence over 2.2 when it was listed in global.json. So I started digging around in the SDK in stall folders (typically located in C:\Program Files\dotnet\sdk). I came across a file named minimumMSBuildVersion In the SDK\3.1.101 folder that file has version 16.3.0 of MSBuild listed. I then went to the SDK 2.2 folder and checked it there. It has version 15.3.0 which my build server has. I simply changed the version to this in the 3.1 folder and my build succeeded. I hope this helps anyone that may still be experiencing build issues when .Net Core SDK versions are updated on their TFS Build Servers.

The target process exited without raising CoreCLR started event error with .NET Core 2.2

I want to debug an empty WebApi Project based on .NET Core 2.2.
I installed the "Core 2.2 SDK x86" and changed the target framework to 2.2:
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>netcoreapp2.2</TargetFramework>
</PropertyGroup>
When I started to debug this project, IIS starts, but in the route api/values I see nothing (it loads forever) and I get this error:
The target process exited without raising a CoreCLR started event.Ensure that the target process is configured to use .NET Core. This may be expected if the target process did not run on .NET Core
In my solution WPF and Class Library projects exist. I wanted to make a WebApi for it. Like I said, it's an empty base project generated by Visual Studio 2019. I just installed Core 2.2. Why do I get that error and what am I doing wrong?
I had the same issue.
I ran Program.cs file from the command line and the error message was different.
So, apparently, I didn't have the appropriate .NET Core runtime installed.
You can download it by the following link - https://dotnet.microsoft.com/download
I was facing the same issue!
I updated my Visual Studios to the most recent via the VS Installer.
While updating, I also added the following VS Workloads:
ASP.NET and web development
.NET desktop development
See about workloads here:
https://github.com/MicrosoftDocs/visualstudio-docs/blob/master/docs/install/modify-visual-studio.md
This worked for me! 😊
I did not have to downgrade or remove anything
I had to do a "clean" and "rebuild" of the project and after that it worked again.
I ran with the same problem. But for me it was that my project was running in .NET Core 2.2, which I didn't have installed. I'm using VS 2019.
So for the solution, just go to Visual Studio Installer and for your VS 2019 hit "Modify" like in the following image (it's in spanish though):
Then, click "Individual Components", like
And then, make sure you checked in ".NET Core 2.2 Runtime (EOL)" (and above like .NET Core 3.0, if you want) and click "Modify", as shown
Hope this works for you.
In my case, switching to x64 save the day.
It seems like there are lots of different causes for this. For me, it was because I had upgraded a .csproj file but I hadn't updated the image used in my docker file.
I had same issue after package upgrading. You don't need any vs update.
Just go to
dotnet.microsoft.com/download/dotnet-core/2.2
and get runtime
dotnet-hosting-2.2.7-win.
I had the same error. Remove "Microsoft.AspNetCore.All" from dependencies.
I have downgraded "Microsoft.AspNetCore.App" version and error gone .
Deleting all bin folders of my solution
building everything again did the trick for me
(.NET Core 3.1 VS 2019)
I see many answers like try and error
after searching about the issue, I got the following :
it simply depends on three parameters and they have to be compatible
Windows platform "x86,x64" you can change it from the CPU option of the visual studio
or choose any CPU hence the install .net x framework should be compatible with the windows
The target framework for the project
(check the project target framework "right-click on the project and check target framework") if it is 5 so the enabled in the third parameter should be 5 or change this one but take care you should tell the other team members if you change it
The Enabled framework go for tools and get tools and go for individuals component and chose the target framework the same as found in step 2 and press modify
Faced this issue during xUnit testing. Downgrading nuget package "Microsoft.NET.Test.Sdk" to 15.9.0 worked for me
I got this error because of a Project reference pointing to a project, that did not exist anymore (was removed in merged git-commit). Solved it by right-clicking the project, then Edit Project File, delete the reference and save.
I was trying to run a project that used net core 2.2 but I didn't have it, and there was no error(I had 1.1), so after installing the 2.2 using the "Visual Studio Installer" it worked like a charm. =)
I restarted my Visual Studio instance in Admin mode and I was able to debug.
After closing Visual Studio I can now start in normal mode and debug as expected. I'm not sure what changed though.
I was missing a reference to AWSSDK.Core. After installing the specific version and re-starting VS2019 and rebuilding, the project ran fine.
All of a sudden it stopped working. For me clean solution and re-build solution worked.
I was getting a similar error with my project: The target process exited without raising a CoreCLR started event.
My startup project was targeting multiple frameworks: netstandard2.0;netcoreapp2.2
I fixed this issue by changing my target framework from netstandard2.0 to netcoreapp2.2 using the following stackoverflow directions: How to switch between target frameworks for .NET Core projects in Visual Studio
Be sure to install the exact version of .net core that you want your project to run on
I had this issue and finally tracked it down to doing a "publish" operation with a deployment mode of: "Self contained" That resulted in dropping all .NET runtime binaries in my bin directory. Where I think things got totally messed up is I have several solutions all using that same common bin directory, each build different exe's and dll's.
Only one was for a self contained deployment as a test. I think that started mixing up some of the minor dlls for the .NET core and causing this issue. Once I purged all the dll's that were "not mine" and rebuilt things started working again. I'm using Visual Studio 2019 16.8.2 / .NET Core 3.1
I realize the original question is regarding .NET Core 2.2 but this question comes up first when searching for the main issue.
.Net Core 2.2 is required to be installed. I fixed when I added this in Visual Studio Installer.
VS2019 16.7.1 ASP.Net Core 3.1
Our Nunit test projects that issued this error, only worked with a very select set of Nunit and Microsoft packages.
Microsoft.NET.Test.sdk - 16.5
Nunit - 3.12
Nunit3TestAdapter 3.16.1
But here's the catch, you have to go into
c:\users\yourname\.nuget\packages and look for all three folders shown above. If you find any other version in those folders, delete it.
I found two versions in the Microsoft.NET.Test.SDK folder. I suspect the newer version was being loaded. Why? Because when I deleted it everything ran fine.
A corrupt layout is also possible, had this happen myself. To fix, go to projpath\bin\x64\configtype\AppX, for example:
C:\Users\Foo\Documents\Visual Studio 2019\projectname\bin\x64\Debug\AppX
Delete everything here, rebuild and you're good to go.
Since I don't see it here yet, here's what worked for me. I have a UWP project, Win32 project, and Windows application packaging project in the same solution. Running the Win32 app using FullTrustProcessLauncher.LaunchFullTrustProcessForCurrentAppAsync was giving this message and not working.
What fixed it was changing a setting in the packaging project's project settings:
Debug -> Debugger type -> Background task process: Native Only
I had same issue. Now in VS2022 you cannot download NetCore2.2.
So just download and install NetCore 2.2 from microsoft dotnet website.
https://dotnet.microsoft.com/en-us/download/dotnet/2.2
This error occurred when I tried changing C# projects in my solution to use Docker and running it:
The error went away when I changed the C# projects back to use the Visual Studio's debug server and running it:
In the Test Explorer window of Visual Studio 2019, make sure that there are no references to any *.testsettings or *.runsettings files if you are not using them intentionally. I had referenced a *.testsettings file unintentionally, and that was causing the issue.
For me, I'd just installed Visual Studio 2022 on a fresh installation of Windows 11. My project uses .Net 5, which wasn't installed by default (I only had .Net 6). I simply used the Visual Studio installer, modified my VS2022, selected Individual Components, and enabled .Net 5. Viola!
I started to get this error after updating Visual Studio from 2019 to 2022. It turned out that the project target framework was set to .Net Core 3.1, which was removed when I uninstalled VS2019, and the solution was to change it to .Net 6.0 which is the component I had selected during installation (Installing .Net Core 3.1 from the Visual Studio Installer should work as well).
To do so, right click on the project name and look for the "Target framework" option (my installation is in Spanish so that's what I presume it should say).
I've encountered this issue multiple times, using VS 2017 and VS 2019 across .NET Core 2.1, 3.1 and 5.0.
There are many conditions that can cause this problem to occur:
Microsoft Update can install a version of .Net Core at any time, automatically and outside of your awareness and knowledge.
It can also change the installation of any .Net Core SDK version's installed components.
Your version of VS has to be compatible with the version of the .Net Core SDK that you have installed.
You must have all of the following components installed for this error to be resolved/pre-empted for .NET 5.0 (please check the dotnet 5.0 site for the compatibility list by versions).
Microsoft .NET SDK 5.0.408 which includes (the following below) must all be installed and listed in the control panel:
.NET Core 5.0.17 Windows Desktop Runtime,.NET Runtime, Windows Server Hosting, Shared Framework
If any .NET Core 3.1 SDK are installed without your knowledge, you must uninstall it and repair your targeted .net core version's installation.

Build error after installing TXTextControl

I have installed TXTextControl .NET 15.1 with a valid license key on a brand-new Windows Server 2016, and I have installed Visual Studio Build Tools 2017 including .NET 4.6.2 and .NET 4.7.2.
When I build my C# project (targeting .NET 4.6.2), I get the following error:
(CompileLicxFiles target) ->
licenses.licx(1): error LC0004: Exception occurred creating type 'TXTextControl.ServerTextControl, TXTextControl, Version=15.1.800.500, Culture=neutral, PublicKeyToken=6b83fe9a75cfb638' System.DllNotFoundException: The TX Text Control kernel DLL file could not be found.
The error The TX Text Control kernel DLL file could not be found hinted at something missing in the GAC, which I then proceeded to check out.
Running the gacutil.exe that came with .NET 4.7.2 indicated that the necessary registrations for
txkernel.dll
txic.dll
txtools.dll
were not there.
I then went on and installed them manually, both the x86 and AMD64 versions, from their respective locations:
C:\Program Files\The Imaging Source Europe GmbH\TX Text Control 15.1.NET\BrowserBin\txkernel.dll
C:\Program Files\The Imaging Source Europe GmbH\TX Text Control 15.1.NET\BrowserBin64\txkernel.dll
etc.
But it still didn't work!
I then contacted support, but their reply was that my license was no longer valid for support, so they basically refused to answer any questions about the product.
After a while I then got the supporter to say that the company never test OLD versions of TXTextControl on NEW versions of Windows, so my best bet would be to purchase a new license.
Since the license is pretty expensive, and our (PERPETUAL!) license is perfectly valid for running the product, I am determined to find a solution to this issue.
Can anyone help me?
After some struggling, I found the solution: Install .NET 3.5 BEFORE installing TXTextControl .NET.
My hypothesis is that the TXTextControl installer fails to check the exit codes, when running gacutil.exe, so it doesn't detect that the registrations have failed.
This means that the recipe for solving this problem (which I post here for Bingle to pick up), is to:
wipe any GAC registrations you may have made in an attempt to manually install the TXTextControl DLLs
uninstall TXTextControl .NET
go to Server Manager and "Add Roles and Features", and then on the "Features" pane, you put a checkmark next to ".NET Framework 3.5 Features" (which causes a single checkmark to be in ".NET Framework 3.5 (includes .NET 2.0 and 3.0)")
reinstall TXTextControl .NET
After this was done, I could build my code!
From having similar sounding issues with the ASP.Net version, make sure that you also have Visual C++ Redistributable Packages for Visual Studio 2013 installed as since v25 this has been required and for any machines that don't already have that installed then the ASP.Net version throws similar errors about txic.dll.

VS2010 C# not including correct .net framework version in target

I am doing maintenance work on a VS2010 C# project built against .net v3.5.
I recently changed the project Target Framework properties to the latest version listed (v4) - due to an expectation of using a version of .net that is actually included in Win10 by default - and rebuilt without any apparent issues.
Unfortunately the embedded dependency in the generated .exe is still for .net v2.0.50727 (which is what is reported for v3.5 AFAIK) and the target machine (a clean install of Win10) is asking to install .net 3.5.
Using MS VS2010 v10.0.40219.1 SP1Rel.
Unfortunately upgrading the build tools isn't an option (building the program with VS2015 works just fine).
I have gone googling but don't seem to have found any similar reports.
Based on some of the comments already posted, I seem to have not made myself entirely clear - hopefully the following will help.
1) the intention/requirement is to be able to install this app on a clean install of Win10 without needing any further downloads. (installing .net 3.5 is easy to do, just not what is wanted)
2) the ultimate build environment for this is automated, visualized and not in my control and therefore upgrading the tool chain is a major pain that I'd like to avoid if possible.
3) AFAIK there are no third party libraries involved. All of the listed references (dll's) are v4.0.30319.
4) this is a XAML-based development, one part of three projects in the solution - the other entries are the installer and a C# custom installation library. As far as I can tell everything is set for .net v4.
Unfortunately the embedded dependency in the generated .exe is still for .net v2.0.50727 (which is what is reported for v3.5 AFAIK) and the target machine (a clean install of Win10) is asking to install .net 3.5
So there is some dependency in your project that targets that version of .NET. It could just be that you need to Build > Clean Solution and with a Build > Rebuild Solution the problem is solved.
Otherwise, assuming some library does require some .NET 3.x library, the installation request is entirely correct. Windows 10 does not have an option for installing .NET 2.0 and another for installing .NET 3.5. If you search for Turn Windows features on or off you will see this:
Any dependency on a .NET 2.x-3.x library will trigger the activation/installation of the first feature in the dialog.
As far as I can see, you have 2 options:
Move everything to a framework supported by Microsoft, most preferably .NET 4.7.2 given support and security.
Deal with the installation process and understand that Microsoft does not install these versions of .NET in purpose. You can, however, add these installers as a prerequisite and even bundle them with your installation, but that won't help much.
Thanks to all who have tried to help me!
The issue has been resolved.
There appear to have been two causes for this issue and my confusion:
it turns out that the blank install of Win10 that the testing was being performed on was not entirely clean - the pre-installed network drivers/utilities from intel also had a .Net v3.5 dependency...
one of the embedded resources in the project was effectively a uncompressed tar-ball containing a number of files; including an executable that had the dependency on .net v3.5 - this was a binary blob stored in svn so the content was had not been updated for several years (ie well before my involvement) ...
With both of these issues addressed it would appear that my problem is solved, so once again thank you for your feedback, suggestions and patience,
PeterT :->

System.core dll can not be referenced

I am trying to solve Dlls reference problem in Visual studio 2012. All dlls have set them self in a way they are looking for .net 4.0 version while I can not install because i have already .Net 4.5 installed with Visual studio 2012.I have asked this Question
but I didnt get a proper answer.Now I am trying to reference System.Core in 4.5 but it can not be referenced as visual studio is not allowing me to do, it says it will be referenced automatically during project build but actually it does not.I am in catch 22 situation.Kindly advise.
I have reinstalled Visual studio 2012 but it didn't help.
Zara, I've looked at the download link you provided and it appears to me it's only for Windows8. Windows7 and Windows8 are very different in how they handle things I personally wouldn't dream of trying to install such an SDK on my Windows7 machine.
My suggestion to you is therefore to try to uninstall the SDK and then it might work again. If this SDK only works for Windows8 then there is no use having it installed on your Windows7 machine. Windows7 is good at keeping backups of all files it replaces when installing SDKs and other things so uninstalling the SDK might restore it to what it was before and it might be just fine after that.
If this doesn't make any difference then I would suggest reinstalling .Net 4.5 AFTER uninstalling the Win8 SDK.

Categories