Recent upgrade to Windows 10 messing up Visual Studio projects

1691
8
Jump to solution
05-28-2019 11:31 AM
BrianBulla
Occasional Contributor III

Hi,

So I just got my PC upgraded to Windows 10.  I'm not sure how the IT department loaded everything.  Previously I was using VS 2012, but now I have VS 2015.  When I open up an old 2012 project I have all sort of missing references, but even after what appeared to be adding them back, I still have 195 "Errors" with my project.  

Any suggestions on how to fix this?  A re-install of the SDK??  My ArcGIS 'templates' within VS seem to be there.

0 Kudos
1 Solution

Accepted Solutions
KimberlyMcCarty
Esri Contributor

Hi Brian,

To answer your question from the post on missing DLLs in the Runtime .NET forum, if when you go to Assemblies - Extensions and don't see any ArcGIS references listed, you likely either need to reinstall the SDK or browse to the location it is installed at and import the DLLs from there.

The DLLs should be located at:

C:\Program Files (x86)\ArcGIS\DeveloperKit10.x\DotNet

From the Assemblies - Extenstions window, click Browse... on the bottom and go to the above location to add the necessary DLLs. Hopefully VS will pick up the location after the first one and just let you check the boxes of the rest you need.

However, since you have a new version of Visual Studio courtesy of your IT, you most likely need to reinstall the  SDK to integrate it with this version of VS. You may need to check the System Requirements of the ArcGIS Desktop version to confirm it is compatible with VS 2015. Otherwise when you try to reinstall it you won't see it listed on the Setup page:

                         

I believe the ArcObjects 10.3 SDK is the last to support VS 2012 so in order to use VS 2015 you may need to upgrade the SDK.

https://desktop.arcgis.com/en/arcmap/10.3/get-started/system-requirements/arcobjects-sdk-system-requ...

Cheers,

Kim

View solution in original post

8 Replies
Egge-Jan_Pollé
MVP Regular Contributor

Hi Brian Bulla‌,

Here Microsoft provides some information that might be relevant to you, including tips on troubleshooting project compatibility issues:

Porting, Migrating, and Upgrading Projects - Visual Studio 2015 | Microsoft Docs 

It looks like you will have to address all 195 errors. But as many of them will be related it might be the case that the moment you solve one of them a whole bunch of errors will be solved at once.

Options to consider:

  • Contact the IT department for help. After all it was them who decided to upgrade both your OS and your VS without warning you beforehand, right?
  • Make a fresh start an rebuild your project from scratch in the 2015 environment. In the long run that might be easier to maintain than an old project that has been ported, migrated and upgraded from a previous version, I would think.

BTW, Microsoft recommends upgrading to Visual Studio 2019...

HTH,

Egge-Jan

KimberlyMcCarty
Esri Contributor

Hi Brian,

To answer your question from the post on missing DLLs in the Runtime .NET forum, if when you go to Assemblies - Extensions and don't see any ArcGIS references listed, you likely either need to reinstall the SDK or browse to the location it is installed at and import the DLLs from there.

The DLLs should be located at:

C:\Program Files (x86)\ArcGIS\DeveloperKit10.x\DotNet

From the Assemblies - Extenstions window, click Browse... on the bottom and go to the above location to add the necessary DLLs. Hopefully VS will pick up the location after the first one and just let you check the boxes of the rest you need.

However, since you have a new version of Visual Studio courtesy of your IT, you most likely need to reinstall the  SDK to integrate it with this version of VS. You may need to check the System Requirements of the ArcGIS Desktop version to confirm it is compatible with VS 2015. Otherwise when you try to reinstall it you won't see it listed on the Setup page:

                         

I believe the ArcObjects 10.3 SDK is the last to support VS 2012 so in order to use VS 2015 you may need to upgrade the SDK.

https://desktop.arcgis.com/en/arcmap/10.3/get-started/system-requirements/arcobjects-sdk-system-requ...

Cheers,

Kim

BrianBulla
Occasional Contributor III

Thanks Kimberly,

I tried updating the references as you suggested, but that still didn't work.  So then I did this:

1.  Uninstall 10.4 SDK

2.  Uninstall VS 2012 (so just 2015)

3.  Reinstall 10.4 SDK

Now all is good, and when I update the references they resolve all the errors.  

Thanks for the help!!

0 Kudos
BrianBulla
Occasional Contributor III

Hi Kimberly McCarty‌,

I thought I had this fixed, but another issue came up.  I cannot seem to get these old 10.2 project to create the .esriAddIn file when I 'Rebuild' them.  I am getting this error:  

Warning Unable to create .esriAddin; missing ESRI ArcGIS Add-in SDK component(s). AsBuilts_AddIn C:\Visual Studio\MODIFIED FOR CONTRACT DB\AsBuilts_AddIn\AsBuilts_AddIn\AsBuilts_AddIn.vbproj 234

I have found this link for what seems to be a similar problem, but following the instructions doesn't seem to help:  https://community.esri.com/message/449786

Thanks,

0 Kudos
KimberlyMcCarty
Esri Contributor

Did following the instructions in that post still result in the same error? These steps should resolve the error, can you please supply a screenshot of the error, the config file showing the version, and the csproj file showing it's been changed to "ESRI.ArcGIS.AddIns.11.targets"?

Also, can you confirm you are using Microsoft .NET Framework 4.5 or above for ArcObjects 10.4 SDK?

0 Kudos
BrianBulla
Occasional Contributor III

Hi Kimberly,

Below is a screen shot of the 'Warning' (not an 'Error').  This is after doing a 'Rebuild' on the project.  As you can see, it says 'Rebuild All succeded', but looking in the AddIns folder there is nothing there.

I've also attached the Config.esriaddinx and the .vbproj files.  One thing is that in the .vbproj I did NOT have to change the text to .11.targets like in the instructions.  It was already like that.  I did change the <AddInTargetVersion> to 10.4 though.

Yes, I am using .NET 4.5 with the 10.4 SDK installed.  Screenshot below....

0 Kudos
KimberlyMcCarty
Esri Contributor

If you create a brand new project from one of the templates, does it build with the same warning?

0 Kudos
BrianBulla
Occasional Contributor III

No, I get a different error, but following the steps here (https://support.esri.com/en/technical-article/000012659) seems to have fixed that problem.

For two projects, I have successfully 're-built' them in VS by starting from scratch, but I really hope I don't have to do that for ALL of my other ArcMap projects I have made previously.

0 Kudos