IIS Express Does Not Recognize Running VS2022 as Admin - visual-studio

I had a computer with VS2019 Community installed. I got a new computer, copied my documents over, and installed VS2022 Community. I am launching VS as admin. In the upper-right corner of VS it says "Admin". Also, when launching VS I get the User Account Control prompt associated with launching as an admin. Yet when I build my solution and launch IIS Express, I get a message "...You do not have permission to access the IIS configuration file. Opening and creating web sites on IIS requires running Visual Studio under an Administrator account". Does anyone know what else to do or have a suggestion of what else to look at? Any help would be appreciated.

Seems the message is a red herring. I incorrectly assumed that IIS Express was installed with VS. The solution was to install IIS Express.

Related

IIS does not list a web site that matches the launched URL

I have sharepoint 2013 application deployed on IIS. When I want to start debugging, I face this error:
"Unable to start debugging on the web server. IIS does not list a web site that matches the launched URL".
I found a few solutions for this issue, but none work for me. The solutions I found:
VS should be running as Administrator. I did that.
Windows Authentication should be enable on IIS. I did that.
'IIS Metabase and IIS 6 configuration compatibility' should be turn on in the Windows features. I did that.
It still doesn't work. Any other solutions? Please help me.
Try to start Visual Studio under administration account by choosing Run as administrator.
If nothing works as above said solutions , try this out
Start >> Control Panel >> Click Programs
Click Turn Windows features on or off.
In the User Account Control dialog box, click Continue
Expand Internet Information Services, expand Web Management Tools, and then expand IIS 6 Management Compatibility
Click to select the IIS Metabase and IIS 6 configuration compatibility check box, and then click OK.
I had this same problem.
I was trying to move my solution to a different DEV server of mine, that I don't use that often.
1.) I had not installed some of the items from the Application Development (duh, right) sections of the IIS Role Services. I ended up checking everything, but I think you only need ASP.NET
2.) I installed the asp.net and web tools 2013 available by clicking here

Cannot debug MVC project due to IIS change(8=>7.5) on VS2012 RC

I have installed web matrix and It has somehow removed the existing IIS Express 8.0, that is installed by default during the VS2012RC installation. I think that is because the web Matrix is using IIS 7.5. So that it has replaced the IIS Express 8 with IIS Express 7.5.
So my tech lead told me to remove the existing IIS 7.5 that has been installed during the installation of Web Matrix, And I removed it. So I have no IIS for debugging. So once I tried to install the IIS 8 manually and it says that there is a existing version of IIS Express 8. So that I can not even install the IIS Express 8.
So I did a repair to my VS2012RC. After a lengthy process it finally gave me a report as
"IIS 8.0 Express
Package failed"
So, Now I am totally stuck with this. Can some one good at this VS stuff help me on this issue.
Another thing is, previously when I open the project and it was not loaded(It says the project is not loaded) So, then when I write click on it and do a reload it said "For debugging you have to have IIS 8.0 and ask me to download it and install ".
When I click next and then it goes to "MS web platform Installer" and direct me to the "IIS 7.5 download page" But the install button was enabled and says its installed. What should I do to overcome this issue. This is like a nightmare.
I also Tried to use "Fix it" and Its beta testing is over and I can not do a proper uninstall of the IIS 8, which says that is still existing.
Thank you.
So, what I did was using MS web platform Installer my option of IIS Express 7.5 and IIS Express 8.0 was gone due to a registry issue. But there was another IIS 8.0 which is compatible with Windows XP and Vista and upper. So I downloaded it installed. It installed in no time and then I opened the project and changed my solution configuration, single start up to my website project. And it worked. That saved me form the havoc that day.
Later I uninstalled the IIS 8.0(Xp compatible) and then did a repair again to my VS 2012 and it installed correctly that time. Then I changed the configuration as said above and done.
If you have the same kind of problem you have to check the configuration also. Since I forgot that this took even longer instead of repairing time for the VS 2012 as well as the system restore.

Visual Studio USE LOCAL IIS WEB SERVER issue with IIS 7.5

My Visual Studio 2010 issues following error when I try to map application to use local IIS:
A larger image can be viewed here:
http://img717.imageshack.us/img717/8323/errorvi.jpg
I run VS2010 as administrator and I have installed (I guess) all necessary services and IIS features.
What could be the reason?
Updated:
Having looked at the error message again, when you say you run as administrator, are you running as an account that a member of the Administrators group or the real Administrator?
If it's an account that's a member of the administrators group then you still need to right click and "Run As Administrator".
Ok. Every time when I reinstalled IIS it suddenly started to work. Then, next day issue reoccured. There was an issue with domain group policy, it turned out that some services were getting disabled with PC reset.

Can't Create or Save File to Network Share in Visual Studio

I'm not certain when this problem started occuring, but it was approximately a few weeks ago when I upgraded from Visual Studio 2008 to 2010. I am on Windows XP Professional. The share is on a server running Windows Server 2003. I have a solution which contains a web site (accessed via UNC path, network share) and some class projects that reside on my local workstation. When I open a file from the website, and try to alter and save the file, I get the following error:
" Cannot access this file. Check security privileges over the network drive."
I've checked privileges on the root folder and I do indeed have full control. Could anyone give me any insight as to what I could be missing?
Are you running Windows Vista or Windows 7 with User Account Control (UAC) enabled? If so, Visual Studio 2010 requires administrator permissions to do certain tasks, including IIS management and network share saving.
Try opening Visual Studio 2010 with the Run as Administrator command. Hope that solves your problem.
Turns out a sysadmin removed all permissions and user profiles from a chunk of servers and forgot to inform me. Thanks for the insight, all.

Web Setup Project not working

'The installer was interrupted before [project name] could be installed. You need to restart the installer to try again.'
I just moved to Win7, and I cannot get the .msi files to install from my Web Setup Projects that are built on that machine. The same projects build and work fine on my other Windows XP, IIS6, VS 2008 SP1 machine. I'm not sure if this is a IIS7 or Win7 issue, but I've done the following:
I have all the IIS/ASP.net compatibility settings checked.
I am an administrator, and I have UAC turned off.
I get the following error when I even try install the .msi file on the Win7 machine and on our existing development server (windows 2003 with IIS6).
I've restarted the windows installer service, and I've added logging for the installer but there is nothing that is showing me what the problem is. Any help would be MUCH appreciated.
I'm running Visual Studio 2005 and had the same problem as you described when moving to Windows 7.
After trying my Web Setup Project .msi file on another computer also running Windows 7 I found that it worked.
When I looked in the "Windows Features" dialog on the working computer I noticed that the IIS had IIS 6 compatibility features turned on. I enabled the same feature on my computer and after that I could install my setup project.
Open up "Control Panel > Programs > Turn Windows features on or off" in Windows 7 and in the "Windows Features" dialog go to "Internet Information Services > Web Management Tools > IIS 6 Management Compatibility" and check the feature "IIS Metabase and IIS 6 configuration compatibility".
Run the installer with full verbose logging:
msiexec /i /lv installLog.txt
Then search the installLog.txt file for "Return Value 3"
This will indicate the exact problem.
Additionally this may help:
http://blog.dragonsoft.us/2009/01/02/visual-studio-2008-and-iis-7/
I solved this by running 'regsvr32.exe actxprxy.dll'
It resolved the following:
Not able to create valid .msi web project in VS 2008.
Start Page in VS2008 was not displaying rss feed in the main window.
IE was not opening up shorted url links to a new tab (in twitter for example).
I suspect this was because of redirects, but I'm not sure. I'm guessing this was a bug in the install process, so I hope this helps others.

Resources