Tip/Trick: Using IIS7 on Vista with VS 2005

A few people have pinged me over the last week asking about how to use VS 2005 with an IIS 7.0 web-site on Windows Vista.  Specifically, they've run into an issue where they see a dialog message asking them to install the FrontPage Server Extensions, or they get a "You must be a member of the administrators group" message when they try to connect (see dialog below):

Bradley has published a nice blog post that describes detailed steps on how to enable VS 2005 to connect to IIS 7.0.  To quickly summarize you need to follow the below two steps to enable it:

1) You need to make sure that you have the the optional "IIS 6 Management Compatibility" option installed within IIS7.  This installs an API for the new configuration system that is compatible with the old Metabase APIs (which is what VS 2005 uses).  You can select this using the "Turn Windows Features on or Off" option in the Vista Control Panel:

 

2) You need to make sure you launch VS 2005 with "elevated" privledges so that you have admin privledges to connect to IIS (this is needed to debug a service, as well as create sites and/or change bindings that impact the entire machine).  You can do this by right-clicking on the VS icon and select the "Run as Administrator" option when launching VS:

Note that this is needed even if your user is already in the administrators group if you have UAC enabled (which is on by default with Vista).  If you disable UAC (which you can also do via the control panel), then this second step isn't required.  Running VS 2005 with "elevated" privledges won't be required if you use the built-in VS 2005 Web-Server (since it has reduced privledges already).  It is only required when connecting and running/debugging with IIS locally.

We'll be updating Visual Studio 2005 to have more accurate error messages to help guide you to the above steps more naturally in the future.  Until then, just use the above steps and you are good to go.

Hope this helps,

Scott

Published Tuesday, September 19, 2006 7:41 AM by ScottGu

Comments

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, September 19, 2006 11:26 AM by Andrey Skvortsov
Try to visit any page and after that "Build" project,you'll get error: Attempted to read or write protected memory. This is often an indication that other memory is corrupt. ...and intellisense dosen't work anymore. What does it means? Thanks.

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, September 19, 2006 9:46 PM by Vincent
Good stuff. The reason I failed to create website by using the IIS is I forget to give the admin right to VS.NET 2005, Thanks.

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, September 19, 2006 11:46 PM by ScottGu

Hi Andrey,

Are you seeing this on each build?  I know there there is an issue with that error message with Vista RC1 (that is now fixed for the final build) that can cause this -- but I don't think it is on each build.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, September 20, 2006 4:33 AM by Josef
Hi Scott, I've still got a ton of .Net 1.1/VS.Net 2003 web apps to maintain. I downloaded Vista RC1 via MSDN and have been having a lot of fun with it in a dual boot. Trouble is, the Web Developer component of VS.Net 2003 won't install on Vista because FrontPage Server Extensions aren't detected. Is there a workaround planned for this or are we stuck keeping XP around for maintenance of older projects?

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, September 20, 2006 10:52 AM by mrmckeb
And there was me spending hours on that problem! Thanks ;)

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Thursday, September 21, 2006 1:17 AM by ScottGu

Hi Josef,

We will have a web download for Frontpage Server Extensions on top of IIS 7.0 at somepoint in the future.  It isn't available/ready yet - but is being worked on currently.

Hope this helps,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Thursday, September 21, 2006 4:35 AM by Josef
Hi Scott, that’s very reassuring. Thanks!

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Thursday, September 21, 2006 5:44 AM by rice
Hi Scott, I've still got a ton of .Net 2.0/VS.Net 2005 express web apps to maintainexpress ,But i publish web apps to iis7 web site,now i have probleum,can't updata data to access 2003,give the mdb to full control(admin),so it can delete table row,but can't updata table,please tell me,why?

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, September 26, 2006 10:38 AM by James
I'm also seeing the same intellisense / 'Attempted to read or write protected memo' issues in RC1

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, September 27, 2006 12:39 AM by ScottGu

Hi David,

Can you send me an email describing the exact error and settings you've made?  I can then loop in some folks to help debug it.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Thursday, September 28, 2006 11:07 AM by ScottGu

Hi Stephen,

Can you send me email with more details on your exact configuration and scenario?  I will then loop in a few additional folks to the thread to help investigate.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Sunday, October 1, 2006 9:12 PM by ScottGu

Hi Jovan,

Can you go into Windows Setup and check to make sure that Windows Authentication is installed for IIS7?  By default it isn't -- so that might be the problem.

Hope this helps,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Monday, October 2, 2006 4:10 AM by Jovan Paskota
Hi Scott! Thanks for the reply but I have installed Windows Authentication for IIS7? Any other tip? Apart from this I must say that VS start and performs much better in Vista than on XP /Jovan

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Monday, October 2, 2006 8:20 PM by ScottGu

Hi Jovan,

Can you send me an email describing your scenario and configuration better?  I'll then loop you in with a few of the debugging folks to help you fix this.

thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, October 3, 2006 5:48 PM by ScottGu

Hi Pradeep,

This is unfortunately a bug in RC1 of Vista.  It is fixed in newer builds of Vista, but right now there probably isn't anyway to work around it.

Sorry!

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Monday, October 16, 2006 3:10 PM by CD
Hi Scott I just upgrated my XP Pro to Vista RC1. I created a website in VS 2005, published it but when I try to run it in my browser, I get the "Service Unavailable" error. I then wen to IIS 7 and realized that the application pool always stops when I run the site in my browser. Do you please have a solution for this problem? Thanks

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, October 17, 2006 10:28 AM by ScottGu

Hi CD,

Can you send me mail with more details about the issue?  I will then loop you in with a few people from the IIS7 team to help.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, October 24, 2006 2:15 PM by ttosh
One thing on the authentication errors. I had to move my app to the classic .net app pool to get it to debug from within Visual Studio, once i did this with the aboved mentioned tips from Scott all worked fine. Tim

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Saturday, November 4, 2006 1:51 AM by vista
i want to vista updata

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, November 7, 2006 4:04 AM by David Myers
When I try to turn on ASP.Net I get an error after it tries to turn it on "An error has occurred. Not all of the features was sucessfully changed". I upgraded from Windows XP to Vista. Any ideas?

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, November 8, 2006 9:41 PM by Yui (I come from Thailand)
Hi Scott I want to know, - What difference between IIS6 and IIS7? - What difference between ASP.NET on windows XP and ASP.NET on windows vista?

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, November 8, 2006 10:10 PM by ScottGu

Hi Yui,

I'd recommend visiting the http://www.iis.net website.  It contains a ton of good material that discusses IIS7.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Thursday, November 9, 2006 12:00 AM by ScottGu

Hi David,

Can you send me an email that describes your configuration and error message more?  I can then help loop you in with someone from the IIS team who can help.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Sunday, November 12, 2006 6:37 PM by Jason H
Hi Scott Is there any more news on the FP Web Extensions being available for download for Vista?

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, November 14, 2006 2:39 PM by ScottGu

Hi Jason,

Can you send me email directly (scottgu@microsoft.com)?  I will then loop you in with the IIS team who can give the best update.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, November 21, 2006 7:47 AM by Brian Edwards

Hi Scott,

I'm getting the same error David got. I upgraded from XP to RTM Vista release and get an error when I try to enable ASP.NET ("An error has occured. Not all of the features were successfully changed").

Thanks,

Brian

(will email you directly as well)

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, November 22, 2006 4:17 AM by Doug Rees

Hi Scott,

I get the same error as David and Brian. This was an upgrade from a XP (.net 1 + 2) machine to RTM.

THanks,

Doug

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Thursday, November 23, 2006 11:17 PM by Terry Humphries

Any update on when the FPSE for IIS 7 will be available?

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Sunday, November 26, 2006 2:06 PM by ScottGu

Hi Terry,

I don't have an updated ETA - but if you want to send me email directly (scottgu@microsoft.com) I'd be happy to loop you in with someone from the team who can update you on it.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, November 29, 2006 4:16 AM by Brian Edwards

Hi James.

Unfortuanately your advice didn't work for me :-(. I get a error when I try to re-register ASP.NET 2.0 using "aspnet_regiis -i" (An error has occurred: 0x80004005 Unspecified error).

There are a whole bunch of errors in the System Event Log: failed to complete process setting package xxx into Installed(Installed) state. The earliest error was:

Windows Servicing failed to complete the process of setting package Windows Foundation (Foundation) into Installed(Installed) state

I'm starting to wonder if I should just reinistall...

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, November 29, 2006 10:02 AM by ScottGu

Hi Brian,

Can you send me email (scottgu@microsoft.com) with details?  I'll then loop in some folks from my team who can help.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, November 29, 2006 3:44 PM by ScottGu

Hi Lee,

Can you send me email with more details about the debugging issue with IIS7?  I can then loop in some folks from the team who can help.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Friday, December 1, 2006 12:38 PM by Keith Nicholson

Scott,

I'm seeing similar situations as described by Brian above while upgrading to Vista RTM from Win XP.  I've used your steps, those from another blog, and a couple of my own, but I keep coming down to the same 0x80004005 error.  I have captured a slew of events.  Can I send these to you as well?  

One of the other oddities I'm seeing which probably relates to this, is that VS 2005 does not provide me the opportunity to even create websites from the start page or from the menu "File".  I have tried different settings and I'm still being denied.

Best Wishes,

Keith Nicholson, MVP C#

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Saturday, December 2, 2006 6:45 PM by ScottGu

Hi Keith,

Could you send me an email with details about the problem you are seeing (email address is: scottgu@microsoft.com)?

I can then loop you in with someone on my team to help investigate and get this fixed.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, December 6, 2006 6:25 PM by Jac

Hi,

I was having problems with the 0x80004005 error when running aspnet_regiis as well.

I removed IIS to try and install it again, but it wouldn’t let me if I tried to install ASP.NET with it…

It’s now sorted for me as I’ve just had some help from a very helpful guy at Microsoft called Gjergji Stasa who Scott reffered me to, so thanks to you too Scott. He said to do this…

Delete the ASP.Net filters manually from the section of %windir%\system32\inetsrv\config\applicationhost.config and try to reinstall ASP.Net along with IIS.

It now all works for me. Hope this helps someone else... :)

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Monday, December 11, 2006 12:07 PM by Sam

I am having problems installing or rather enabling IIS7 in vista. every time I try, no matter which options I choose, I get the following error message:

"An error has occurred. Not all of the features were successfully changed"

Is there anything at all I can do to sort this out?

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Monday, December 11, 2006 4:13 PM by Mike

I cant send any email out using localhost. maaybe I missed something using VS2005 and Vista.

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, December 12, 2006 2:47 AM by Brian Edwards

Thanks Jac. I went through the applicationhost.config file and I deleted all the entries that weren't absolutely necessary and finally managed to get my ASP.NET to install.

I much appreciate the advise :o)

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Wednesday, December 27, 2006 12:18 PM by Wyatt Preul

Solution to "An error occurred..."

Open C:\Windows\System32\inetsrv\config\applicationhost.config

Remove ISAPI filter entries inside the <isapiFilters> sections.

Stop the w3svc with "net stop w3svc"

run "aspnet_regiis -i"

Start the w3svc with "net start w3svc"

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Sunday, January 14, 2007 10:11 PM by Gsus

when the FPSE for IIS 7 will be available?

how i install VS2003 with web development?

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Sunday, January 14, 2007 10:17 PM by ScottGu

Hi Gsus,

If you want to send me email directly, I can loop you in with someone from the team to get an update on FPSE for IIS7.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Tuesday, January 30, 2007 11:51 PM by Tim

Scott, any update on availability of FPSE for IIS7?

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Monday, February 12, 2007 3:16 PM by Jason

JAC. you rock!. that totally worked

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Monday, February 19, 2007 10:59 AM by ScottGu

Hi mansachs,

I'm really sorry to hear you are having problems.  Can you send me email at scottgu@microsoft.com repeating this question?  I will then put you in touch with someone who can help guide you through it and make sure you are up and running.

Thanks,

Scott

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Thursday, March 15, 2007 9:37 AM by Fred

Scott,

when i install sql 2005 express advanced, the repoting services dont create your pages on iis.

This is related with admin permissions?

do you have any solution for this ?

thanks.

# re: Tip/Trick: Using IIS7 on Vista with VS 2005

Friday, March 16, 2007 2:41 AM by ScottGu

Hi Fred,

Can you send me an email about this question?  I can then loop you in with someone who can help.

Thanks,

Scott