Visual Studio IIS Express hangs on launch, but IIS local works, why?

前端 未结 9 460
余生分开走
余生分开走 2020-12-25 11:12

I run Visual studio 2015 as administrator, start a new project, ASP.NET application, Empty 4.5.2 and then just add a simple html page. When I try to launch using IIS Expres

相关标签:
9条回答
  • 2020-12-25 11:30

    Sometimes Visual Studio just takes many minutes to load all the required symbols when debugging. Check the status bar of Visual Studio:

    Once for some reason IIS Express worked if I changed the browser targeted in Visual Studio to Google Chrome. Simply restarting Visual Studio fixed this for me though.

    0 讨论(0)
  • 2020-12-25 11:30

    Solution:
    1. Run VS as Administrator. Open your sln, Start debugging, stop and close the VS.
    2. Again open the sln (without admin) file and start debugging.
    It worked!

    Problem:
    - My VS2017 was running fine with debugging, until some other tool's installation corrupted it. Then I reinstalled it. When I started debugging/running site, it wasn't even opening first page of site. It was keep loading assemblies forever. I tried many things found on google. It didn't help.
    - Finally I tried opening it with Admin and then regular. It solved my problem.

    0 讨论(0)
  • 2020-12-25 11:34
    1. Right click on your web Project and click properties
    2. Go to web tab on the right
    3. In the server section, change local IIS to IIS Express

    Hope this helps

    0 讨论(0)
  • 2020-12-25 11:35

    I had same problem and all advices not working. But I run visual studio as administrator and all working now. So, go to shortcut of visual studio, properties, advance..., and check run as administrator.

    0 讨论(0)
  • 2020-12-25 11:41

    Exit Visual studio and delete the (project).vs folder. Restart Visual studio. It should start working.

    0 讨论(0)
  • 2020-12-25 11:47

    Look into applicationhost.config file under

    YOUR_DOCUMENTS_PATH\IISExpress\config\

    Localize defaultDocument setting and add your static html page full name (yourpage.html) or use one of the options available if you want to stick to the standards:

       <defaultDocument enabled="true">
            <files>
                <add value="Default.htm" />
                <add value="Default.asp" />
                <add value="index.htm" />
                <add value="index.html" />
                <add value="iisstart.htm" />
                <add value="default.aspx" />
            </files>
        </defaultDocument>
    
    0 讨论(0)
提交回复
热议问题