[英]The configuration section 'system.ServiceModel' cannot be read, missing section declaration
I am following the documentation from http://docs.nuget.org/create/hosting-your-own-nuget-feeds to set up a Nuget Server. 我正在遵循http://docs.nuget.org/create/hosting-your-own-nuget-feeds中的文档来设置Nuget服务器。 I have followed all the steps, but when I run VS I get the error above.
我已经按照所有步骤操作,但是运行VS时出现上述错误。 From the error I am missing a section, but what section am I missing and how do I add that section.
由于错误,我缺少了一个部分,但是我缺少了哪个部分以及如何添加该部分。 I have searched stack and google and have been unable to find an answer.
我已经搜索了堆栈和谷歌,一直找不到答案。 Here is the code for the web.config
这是web.config的代码
?xml version="1.0"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
<system.web>
<compilation debug="true" targetFramework="4.5.2"/>
<httpRuntime targetFramework="4.5.2"/>
</system.web>
<appSettings>
<add key ="packagePath" value="E:\HostedNugetServer"/>
</appSettings>
<system.ServiceModel>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true"/>
</system.ServiceModel>
</configuration>
This may be just a typo in your post, but your system Service Model declaration should be with a lower-case "s" on the serviceModel. 这可能只是您的帖子中的错字,但您的系统服务模型声明应在serviceModel上使用小写的“ s”。
<system.serviceModel>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true"/>
</system.serviceModel>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.