Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
790 views
in Technique[技术] by (71.8m points)

visual studio - Error HRESULT E_FAIL has been returned from a call to a COM component VS2012 when debugging

I have a problem debugging a project migrated from Visual Studio 2010 to 2012. Every time I go to debug it I get the error message:

"Error HRESULT E_FAIL has been returned from a call to a COM component".

Compiling and running the application in a local IIS server works fine - just cannot debug.

The other change other than moving to VS2012 is I am now using Team Foundation Server for source control and issue tracking - but I cannot see how that would affect it.

I can narrow it down to the following

  • The project file - it has been migrated from VS 2003 as a website project and has been chopped and changed up the different versions
  • Crystal Report runtime library/ some other library

Anyone with any ideas?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

I have been getting this a lot lately. I've been having to create a new file and move the code to the new file to get around it.

I fixed it by deleting the solution's suo file (as far as I can tell, it just stores info like what files are open in the IDE and stuff, and deleting it does no real damage).

My file was seemingly corrupt. (The IDE wouldn't remember what files were open when restarting. It was 1.7MB in size, which seems large, even for my 40 project solution, which rarely has more than 50 files open at once.)

Edit: I just recently had to do this in VS2017 but for another reason, it was taking longer to build and took 5+ minutes to stop a debug session, deleting that pesky suo file fixed it right up, now anytime VS acts weird deleting SUO is my first port of call.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...