Skip to content

System.Runtime.InteropServices.COMException when opening an ASP.NET Project

by Cory Foy on July 15th, 2009

This morning I was opening an ASP.NET project on my Win7 box in Visual Studio 2008, when a message popped up which only said:

System.Runtime.InteropServices.COMException

If you run into this, there are three things you need to do:

  1. Make sure you have IIS installed – This sounds silly, but since I had just rebuilt my box, I had forgotten to turn it on
  2. Make sure you are running VS as Administrator – if you haven’t mapped the ASP.NET Project to an IIS location, then Visual Studio will need Administrator privileges to modify the IIS metabase. Speaking of the IIS Metabase…
  3. Make sure you have “IIS Metabase and IIS6 Configuration Compatability” turned on – See Robert Boedigheimer’s article which was oh-so-handy.

There’s also a Microsoft Connect Bug that has already been filed and says it will be fixed in an upcoming service pack.

From → Uncategorized

One Comment
  1. Thanks a lot. This solution worked out great for me. I indeed had some projects in my solution that required iis in order to run.
    Thinking of using visual studio’s built in web server, this makes the solution more portable.

Leave a Reply

Note: XHTML is allowed. Your email address will never be published.

Subscribe to this comment feed via RSS