Server Error in '/' Application.Item has already been added. Key in dictionary: 'RegistryPermission'

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/cplvfx/article/details/81905591

汉议:服务器错误:字典中的关键字:“RegistryPermission”所添加的关键字:“RegistryPermission”

“/”应用程序中的服务器错误。

--------------------------------------------------------------------------------

已添加项。字典中的关键字:“RegistryPermission”所添加的关键字:“RegistryPermission”

说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。

异常详细信息: System.ArgumentException: 已添加项。字典中的关键字:“RegistryPermission”所添加的关键字:“RegistryPermission”

源错误:

执行当前 Web 请求期间生成了未处理的异常。可以使用下面的异常堆栈跟踪信息确定有关异常原因和发生位置的信息。

堆栈跟踪:

[ArgumentException: 已添加项。字典中的关键字:“RegistryPermission”所添加的关键字:“RegistryPermission”]

System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add) +7488744

System.Collections.Hashtable.Add(Object key, Object value) +11

System.Security.Policy.PolicyLevel.FromXml(SecurityElement e) +307

System.Security.SecurityManager.LoadPolicyLevelFromStringHelper(String str, String path, PolicyLevelType type) +207

System.Security.SecurityManager.LoadPolicyLevelFromString(String str, PolicyLevelType type) +37

System.Web.HttpRuntime.CreatePolicyLevel(String configFile, String appDir, String binDir, String strOriginUrl, Boolean& foundGacToken) +420

System.Web.HttpRuntime.SetTrustLevel(TrustSection trustSection, SecurityPolicySection securityPolicySection) +8957662

System.Web.HttpRuntime.HostingInit(HostingEnvironmentFlags hostingFlags) +186

[HttpException (0x80004005): 已添加项。字典中的关键字:“RegistryPermission”所添加的关键字:“RegistryPermission”]

System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +8929199

System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +85

System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +333

Server Error in '/' Application.


Item has already been added. Key in dictionary: 'RegistryPermission'  Key being added: 'RegistryPermission'

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.ArgumentException: Item has already been added. Key in dictionary: 'RegistryPermission'  Key being added: 'RegistryPermission'

Source Error: 
 

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


Stack Trace: 
 

[ArgumentException: Item has already been added. Key in dictionary: 'RegistryPermission'  Key being added: 'RegistryPermission']
   System.Web.HttpRuntime.HostingInit(HostingEnvironmentFlags hostingFlags, PolicyLevel policyLevel, Exception appDomainCreationException) +280

[HttpException (0x80004005): Item has already been added. Key in dictionary: 'RegistryPermission'  Key being added: 'RegistryPermission']
   System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +10075596
   System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +95
   System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +254

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.7.3062.0

解决方案:

服务器网站中安全狗中安全模式设置 .net版本 2.0 选完整模式

猜你喜欢

转载自blog.csdn.net/cplvfx/article/details/81905591