该篇文章是我于2009年6月10日通过自己编写的工具,批量从位于在博客园的博客站点(http://chenxizhang.cnblogs.com)同步而来。文章中的图片地址仍然是链接到博客园的。特此说明! 陈希章原文地址:http://www.cnblogs.com/chenxizhang/archive/2008/12/27/1363775.html原文标题:Infopath表单错误 原文发表:2008/12/27 13:35:00 |
下午设计了一个Infopath表单,里面包含了自定义代码,需要去访问webservice。部署到SharePoint的时候,出现下面这一大串错误。当时一下子没有找到原因。回来仔细想了想,居然就是因为没有在选项中设置"完全信任"导致的。惨痛啊,真是让人抓狂的Infopath,不知道啥时候就冒出来一个问题就能让你搞半天
======================================================================================================================================
请求“Microsoft.SharePoint.Security.SharePointPermission, Microsoft.SharePoint.Security, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c”类型的权限已失败。
System.Security.SecurityException: 请求“Microsoft.SharePoint.Security.SharePointPermission, Microsoft.SharePoint.Security, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c”类型的权限已失败。
在 System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Assembly asm, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed)
在 System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Object assemblyOrString, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed)
在 System.Security.CodeAccessSecurityEngine.CheckSetHelper(PermissionSet grants, PermissionSet refused, PermissionSet demands, RuntimeMethodHandle rmh, Object assemblyOrString, SecurityAction action, Boolean throwException)
在 System.Security.CodeAccessSecurityEngine.CheckSetHelper(CompressedStack cs, PermissionSet grants, PermissionSet refused, PermissionSet demands, RuntimeMethodHandle rmh, Assembly asm, SecurityAction action)
在 请假单.FormCode.FormEvents_Loading(Object sender, LoadingEventArgs e)
在 Microsoft.Office.InfoPath.Server.SolutionLifetime.FormEventsHost.<>c__DisplayClass6.<>c__DisplayClass8.
b__1()
在 Microsoft.Office.InfoPath.Server.Util.DocumentReliability.InvokeBusinessLogic(Thunk thunk)
在 Microsoft.Office.InfoPath.Server.SolutionLifetime.FormEventsHost.<>c__DisplayClass6.
b__0(Object sender, LoadingEventArgs e)
在 Microsoft.Office.InfoPath.Server.SolutionLifetime.FormEventsHost.<>c__DisplayClass34.
b__30()
在 Microsoft.Office.InfoPath.Server.DocumentLifetime.OMExceptionManager.CallFormCodeWithExceptionHandling(UserMessages userMessages, OMCall d)
在 Microsoft.Office.InfoPath.Server.SolutionLifetime.FormEventsHost.FireLoadingEvent(Document document, Dictionary`2 inputParameters)
在 Microsoft.Office.InfoPath.Server.DocumentLifetime.Document.PerformOnLoadEvent(Dictionary`2 intputParameters)
在 Microsoft.Office.InfoPath.Server.DocumentLifetime.Document.LoadSolutionAndDocument(HttpContext context, Solution solution, DocumentMetaInformation documentMetaInformation, OnInitializeCallback onInitializeCallback, OpenParameters openParameters)
在 Microsoft.Office.InfoPath.Server.DocumentLifetime.Document.OpenDocumentWithSolution(HttpContext context, SPSite contextSite, Solution solution, DocumentMetaInformation documentMetaInformation, OnInitializeCallback onInitializeCallback, OpenParameters openParameters)
在 Microsoft.Office.InfoPath.Server.DocumentLifetime.Document.NewFromSolution(HttpContext context, SPSite contextSite, Solution solution, DocumentMetaInformation documentMetaInformation, Boolean disableFirstRequestOptization, OnInitializeCallback onInitializeCallback, OpenParameters openParameters)
在 Microsoft.Office.InfoPath.Server.Controls.XmlFormView.DataBindInternal(SolutionMetaInformation solutionMetaInformation, DocumentMetaInformation documentMetaInformation, String absoluteSolutionLocation, Boolean hasCloseHandler, Document& document)
在 Microsoft.Office.InfoPath.Server.Controls.FormServerPage.InitializeRenderInLine(SolutionMetaInformation solutionMetaInformation, DocumentMetaInformation documentMetaInformation, String absoluteSolutionLocation)
在 Microsoft.Office.InfoPath.Server.Controls.FormServerPage.NewEditingSession(SPSite contextSite, FormServerPageQueryParameters queryParameters)
在 Microsoft.Office.InfoPath.Server.Controls.XmlFormView.StartNewEditingSession()
在 Microsoft.Office.InfoPath.Server.Controls.XmlFormView.EnsureDocument(EventLogStart eventLogStart)
在 Microsoft.Office.InfoPath.Server.Controls.XmlFormView.<>c__DisplayClass3.
b__1()
在 Microsoft.Office.Server.Diagnostics.FirstChanceHandler.ExceptionFilter(Boolean fRethrowException, TryBlock tryBlock, FilterBlock filter, CatchBlock catchBlock, FinallyBlock finallyBlock)
失败的操作是:
LinkDemand
失败的第一个权限的类型是:
Microsoft.SharePoint.Security.SharePointPermission
失败的第一个权限是:
version="1"
ObjectModel="True"/>
该请求用于:
version="1">
version="1"
ObjectModel="True"/>
被授予的失败程序集的集合为:
version="1">
version="1"
Read="USERNAME"/>
version="1"
Unrestricted="true"/>
version="1"
Read="C:/Program Files/Common Files/Microsoft Shared/Web Server Extensions/12/Template/Features/FT-01-7da54b18-1403-6b98-5184-cf8ae8182fa7/solution.xsn.1.0.0.11.1.0.0.11/"
PathDiscovery="C:/Program Files/Common Files/Microsoft Shared/Web Server Extensions/12/Template/Features/FT-01-7da54b18-1403-6b98-5184-cf8ae8182fa7/solution.xsn.1.0.0.11.1.0.0.11/"/>
version="1"
Allowed="AssemblyIsolationByUser"
UserQuota="9223372036854775807"
Expiry="9223372036854775807"
Permanent="True"/>
version="1"
Flags="ReflectionEmit"/>
version="1"
Flags="Assertion, Execution, BindingRedirects"/>
version="1"
Unrestricted="true"/>
version="1"
PublicKeyBlob="0024000004800000940000000602000000240000525341310004000001000100EF2997493CA56265D1A61D7239C4EE0B1CF4920BA51935B70987008905A5D248E00913F5F0A297EC7564105A1A6BF683D2AF0D19AA7CA285303A7F7D12ADACD26E5D3A5BA41C7AA15F72737AE265FE43E2FE9928E5973D8539EE14A72298915F88DBDF4759B500B3FA08C74B04A1BB7B00659518D59AAF04E6AB5E6E3BA418A8"
Name="___"
AssemblyVersion="1.0.3283.36267"/>
version="1"
Url="file:///C:/Program Files/Common Files/Microsoft Shared/Web Server Extensions/12/Template/Features/FT-01-7da54b18-1403-6b98-5184-cf8ae8182fa7/solution.xsn.1.0.0.11.1.0.0.11/___.dll"/>
version="1"
Zone="Intranet"/>
version="1"
Unrestricted="true"/>
version="1"
Level="DefaultPrinting"/>
version="1"
Audio="SafeAudio"
Video="SafeVideo"
Image="SafeImage"/>
version="1"
Level="Safe"/>
失败的程序集或 AppDomain 是:
___, Version=1.0.3283.36267, Culture=neutral, PublicKeyToken=1739f43caf0ddcd4
失败的程序集的区域是:
Intranet
失败的程序集的 Url 是:
file:///C:/Program Files/Common Files/Microsoft Shared/Web Server Extensions/12/Template/Features/FT-01-7da54b18-1403-6b98-5184-cf8ae8182fa7/solution.xsn.1.0.0.11.1.0.0.11/___.dll
作者:陈希章 出处:http://blog.csdn.net/chen_xizhang 本文版权归作者所有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。 |