简体   繁体   English

在Visual Studio 2017社区上打开项目/解决方案时出错

[英]Error opening a project/solution on Visual Studio 2017 Community

I am trying to open a project/solution on Visual Studio 2017 Community and i get the next error: 我正在尝试在Visual Studio 2017社区上打开项目/解决方案,但出现下一个错误:

在此处输入图片说明

I have been googling for this error but i haven't found any solution. 我一直在搜寻此错误,但尚未找到任何解决方案。 Any suggestions? 有什么建议么?

I hope to have explained well my problem. 我希望能很好地解释我的问题。

Update 更新

I am using VS17 on a Virtual Machine with Windows7 32bits. 我在具有Windows7 32位的虚拟机上使用VS17。

I tried the solution proposed by Andrii to delete all <site> inside the <sites> node under the applicationhost.config file but after restarting VS2017 and launch my project, I got the following error: 我尝试了Andrii提出的解决方案来删除applicationhost.config文件下<sites>节点内的所有<site> ,但是在重新启动VS2017并启动我的项目后,出现以下错误:

Unable to connect to web server 'IIS Express' 无法连接到Web服务器“ IIS Express”

In the config file, I had to put back the application pool like the following: 在配置文件中,我不得不像下面那样放回应用程序池:

<site name="MyApp" id="1">
    <application path="/" applicationPool="Clr4IntegratedAppPool"> <-- HERE
        <virtualDirectory path="/" physicalPath="C:\Git\MyApp\MyApp" />
    </application>
    <bindings>
        <binding protocol="http" bindingInformation="*:61508:localhost" />
    </bindings>
</site>
<applicationDefaults applicationPool="Clr4IntegratedAppPool" /> <-- AND HERE

After that restart VS2017 and try again. 之后,重新启动VS2017,然后重试。

Also you might just look at the physicalPath folder specified in the config file... make sure it is writable. 另外,您可能只需要查看配置文件中指定的physicalPath文件夹即可...确保其可写。 Some people specified they had the problem when the folder is encrypted. 有人指定加密文件夹时出现问题。 You can find some other possible solution here: 您可以在此处找到其他可能的解决方案:

Creating a virtual directory failed with the error 创建虚拟目录失败,并显示以下错误

I had the same issue few weeks ago. 几周前我遇到了同样的问题。 Solved it by opening applicationhost.config mentioned in the error and removing all <site> nodes under the <sites> and then reopening VS. 通过打开错误中提到的applicationhost.config并删除<sites>下的所有<site>节点,然后重新打开VS来解决此问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM