Did you have encounter Microsoft.Cpp.Default.props not found error when you execute npm install in your Angular project? Have you tried solutions like installing the build tools, registry, etc.? You might have similar issues with my machine, from my team, I'm the only one I've encountered this error which was strange. I've tried the solutions I've found in the net, reinstalled the build tools and I even edited my registry. It seems no hope for me, I've stopped what I'm doing and analyzed the problem: `error MSB4019: The imported project "C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Default.props " was not found. Confirm that the path in the <Import> declaration iscorrect, and that the file exists on disk.` From here, I know that the application cannot find this file so I'm thinking to just locate and copy the missing files which works on my end. So, my first step here is to locate the actual folder but upon checking the VCTarget folder doesn't exists at all.

Fixing Microsoft.Cpp.Default.props error not found

February 21, 2021
By TonyTony  Tony

Did you have encounter Microsoft.Cpp.Default.props not found error when you execute npm install in your Angular project? Have you tried solutions like installing the build tools, registry, etc.? You might have similar issues with my machine, from my team, I'm the only one I've encountered this error which was strange. I've tried the solutions I've found in the net, reinstalled the build tools and I even edited my registry. It seems no hope for me, I've stopped what I'm doing and analyzed the problem: `error MSB4019: The imported project "C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Default.props " was not found. Confirm that the path in the <Import> declaration iscorrect, and that the file exists on disk.` From here, I know that the application cannot find this file so I'm thinking to just locate and copy the missing files which works on my end. So, my first step here is to locate the actual folder but upon checking the VCTarget folder doesn't exists at all.
Finding VC Targets folder.

I've remembered that I've installed windows build tools from npm, so I've tried to locate that. And from there, I've found the VCTargets folder. I've copy this folder and paste to the Visual 2019 Build Tools folder. Finally, after I've copied the folder, I've run npm install and this time it's a success.

Hope this could help somehow, happy coding.

Other Dev Series
Blazor: Starting Up

View details

Building up your first website starting with new Blazor WebAssembly Project

Blazor: Indexed DB

View details

Saving and retrieving data from IndexedDb using your existing Blazor WASM Project

Angular: Fixing Cpp error

View details

Fixing Microsoft.Cpp.Default.props error not found

Leave a reply

Let me know if I could help more.

Your e-mail address will not be published.

arrow_upward