VS 2012 can't load project which uses IIS with custom binding host - thinks it's using IIS Express

前端 未结 12 900
清酒与你
清酒与你 2020-12-07 21:35

I have an ASP.NET project which uses IIS. IIS site is configured to use custom binding host name. Project file contains following settings:

...


        
相关标签:
12条回答
  • 2020-12-07 22:10

    In my case deleting the *.csproj.user file worked fine

    0 讨论(0)
  • 2020-12-07 22:10

    This problem was ruining my day in VS 2013 today. I tried all of the above, but didn't get the project to load until I created a Web site in IIS and filled in this section in the .csproj file (especially the IISUrl element):

    <ProjectExtensions>
        <VisualStudio>
          <FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
            <WebProjectProperties>
              <UseIIS>True</UseIIS>
              <AutoAssignPort>True</AutoAssignPort>
              <DevelopmentServerPort>81</DevelopmentServerPort>
              <DevelopmentServerVPath>/</DevelopmentServerVPath>
              <IISUrl>http://localhost/SomeProject</IISUrl>
              <NTLMAuthentication>False</NTLMAuthentication>
              <UseCustomServer>False</UseCustomServer>
              <CustomServerUrl>
              </CustomServerUrl>
              <SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
            </WebProjectProperties>
          </FlavorProperties>
        </VisualStudio>

    0 讨论(0)
  • 2020-12-07 22:13

    For me combination of both worked for Visual Studio 2015 Preview with Windows 7 64 bit:
    1. delete *.csproj.user file and
    2. <UseIISExpress>false</UseIISExpress> in Solution File.
    Steps for Step 2:In Visual Studio Right Click on Project==> Unload ===> Edit the Solution

    0 讨论(0)
  • 2020-12-07 22:13

    If your project is part of a solution, Open the solution file (.sln) and edit the project section.

    ProjectSection(WebsiteProperties) = preProject
        UseIISExpress = "false"
    

    It Worked for me.

    0 讨论(0)
  • 2020-12-07 22:23

    This is enough

    Comment this line in project file x.csproj

    <!--<UseIIS>True</UseIIS>-->
    

    x.csproj : error : The URL 'http://localhost/x' for Web project 'x' is configured to use IIS Express as the web server but the URL is currently configured on the local IIS web server. To open this project, you must use IIS Manager to remove the bindings using this URL from the local IIS web server.

    0 讨论(0)
  • 2020-12-07 22:25

    The solution is: delete *.csproj.user file!

    0 讨论(0)
提交回复
热议问题