Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Could not load file or assembly Microsoft.ServiceHosting.Tools

I just got a new workstation set up and I installed VS 2013 with Windows Azure SDK 2.3 first. But then I realized that our project was built upon Windows Azure SDK 2.2. So I uninstalled the SDK 2.3 and then installed 2.2. After that, I got the project from TFS and tried to run it and there was a problem:

Cannot debug the project because some run time file was missing.

So I tried to repair it by uninstalling Windows Azure SDK 2.2 completely and repair my VisualStudio. But now I get this error message:

Could not load file or assembly 'Microsoft.ServiceHosting.Tools, Version=1.0.0.0, Culture =neutral, PublicKeyToken=232wedsfd3f4' or one of its dependencies. The system cannot find the file specified.

I looked through the project and there wasn't any reference of Miscrosoft.ServiceHosting. And the database and cloud are working. No idea what happened in the machine since Azure is a new field for me. Does anybody ever meet the same problem?

like image 763
Ruoyu Jiang Avatar asked Apr 17 '14 07:04

Ruoyu Jiang


3 Answers

In my case, I have VS 2012. I was trying to develop an Azure web service. The error I'm encountering was

'Could not load file or assembly ***'Microsoft.ServiceHosting.Tools'***'

The issue was resolved after installing Microsoft Azure Emulator and Microsoft Azure Storage Emulator.

like image 85
ptsivakumar Avatar answered Nov 07 '22 10:11

ptsivakumar


I found the cause to be a corrupt Azure SDK installation on my machine with VS.NET 2013.

Reinstalling the Azure SDK from here (http://azure.microsoft.com/en-us/downloads/) and restarting VS.NET to clean and build the solution worked for me and got rid of the build error from the OP.

like image 3
atconway Avatar answered Nov 07 '22 10:11

atconway


I finally solve the problem! But I won't delete the post because I think some other people might meet the same problem.

My problem was caused by OS (Win8.1 Ultimate) which doesn't support Hyper-V so that Azure Emulator couldn't be installed. After installing Windows Pro or Enterprise the problem will be solved!

Hopefully can help somebody who run into the same problem as me.

like image 1
Ruoyu Jiang Avatar answered Nov 07 '22 10:11

Ruoyu Jiang