我在ASP.NET和Web配置文件中得到這個錯誤初學者:
爲什麼我在ASP.NET的web配置中出現錯誤?
web config section must only appear once per config file
我的網絡配置文件:
<system.web>
<httpRuntime maxRequestLength="1048576" executionTimeout="3600" />
<httpHandlers>
<add path="ChartImg.axd" verb="GET,HEAD,POST" type="System.Web.UI.DataVisualization.Charting.ChartHttpHandler, System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>
</httpHandlers>
<pages>
<controls>
<add tagPrefix="asp" namespace="System.Web.UI.DataVisualization.Charting" assembly="System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
</controls>
</pages>
<compilation targetFramework="4.0">
<assemblies>
<add assembly="System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</assemblies>
</compilation>
<httpRuntime/>
</system.web>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" warningLevel="4" compilerOptions="/langversion:4 /nowarn:1659;1699;1701">
<providerOption name="CompilerVersion" value="v4.0"/>
</compiler>
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:14 /nowarn:41008 /define:_MYTYPE=\"Web\" /optionInfer+"/>
</compilers>
</system.codedom>
<connectionStrings>
<add name="myCaseLoginEntities" connectionString="metadata=res://*/MyEntity.LoginModel.csdl|res://*/MyEntity.LoginModel.ssdl|res://*/MyEntity.LoginModel.msl;provider=System.Data.SqlClient;provider connection string="data source=.;initial catalog=myCase;integrated security=True;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient"/>
<add name="myCaseConnectionString" connectionString="Data Source=.;Initial Catalog=myCase;Integrated Security=True" providerName="System.Data.SqlClient"/>
<add name="CaseManagementConnectionString" connectionString="Data Source=.;Initial Catalog=CaseManagement;Integrated Security=True" providerName="System.Data.SqlClient"/>
</connectionStrings>
我加入這行到該文件:
<httpRuntime maxRequestLength="1048576" executionTimeout="3600" />
在此之前,我沒有任何錯誤。我該如何解決這個問題謝謝。
也許是因爲你宣稱它是自閉的兩倍? – Randy
如果只有錯誤信息會說出錯的地方。 –