Tuesday, March 5, 2013

Visual Studio 2012 - An error occurred while trying to load some required components

I have three SharePoint 2013 virtual machines for development. On two of them, when trying to create a new project with "SharePoint 2013 - Empty Project" template, I got the error message:

"An error occurred while trying to load some required components. Please ensure that the following prerequisite components are installed:
Microsoft Web Developer Tools
Microsoft Exchange Web Services"


I don't see much difference among these three virtual machines. 
Google leads me to here first. I tried to register the dll in GAC, with no luck.
EwsManagedApi32.msi addlocal="ExchangeWebServicesApi_Feature,ExchangeWebServicesApi_Gac"
Then I found the post Prerequisite components error when creating a Visual Studio 2012 SharePoint 2013 App project .   It makes sense. So I followed it, with no luck.
Then I found that the module "Microsoft Exchange Web Services Managed API 2.0" was not installed with "Microsoft Office Developer Tools for Visual Studio 2012"!
Finally I realized the problem: I downloaded the full package of "Microsoft Office Developer Tools for Visual Studio 2012", which is called "officetools_bundle.exe".  But, obviously it's not enough to just install this module, and it needs to cooperate with a lot of other modules.
So, I uninstalled "Microsoft Office Developer Tools for Visual Studio 2012", and reinstalled it through "OfficeToolsForVS2012RTW.exe". This time, it works well.
Below is a screenshot I got at the end of the installation. We can see how many modules are installed and configured with "Microsoft Office Developer Tools for Visual Studio 2012".

No comments:

Post a Comment