未将对象引用设置到对象的实例。
说明: 执行当前 Web 请求期间,出现未经处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。
异常详细信息: System.NullReferenceException: 未将对象引用设置到对象的实例。
源错误:
行 80: {
行 81:
行 82: vCurrentListUrlAsHTML = "<%= Web.Url + "/" + (CurrentList.RootFolder.Url.Length > 0 ? CurrentList.RootFolder.Url + "/" : "") %>";
行 83: vCurrentWebUrl = "<%= Web.Url %>";
行 84: var destinationFolder;
源文件: c:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\TEMPLATE\LAYOUTS\upload.aspx 行: 82
堆栈跟踪:
[NullReferenceException: 未将对象引用设置到对象的实例。]
ASP._layouts_15_upload_aspx.__Render__control29(HtmlTextWriter __w, Control parameterContainer) in c:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\TEMPLATE\LAYOUTS\upload.aspx:82
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +130
Microsoft.SharePoint.WebControls.ScriptBlock.Render(HtmlTextWriter writer) +284
是开发的,是sp自身的功能。如果把用户加入sp默认的管理员组里,就可以正常编辑,如果单独给用户设置管理员权限,就报这个错。
我的环境里测试了一下,把一个用户单独赋予Full Control的权限,然后在IE和Chrome中,分别使用上传和拖拽的方式,都没有这个问题。
你试过其他的浏览器吗?其他用户呢?其他的文档库呢?
When I tried to Open dialog box of Upload Multiple Documents (OOTB) in Custom Document Library and I got "An unexpected error has occurred" Message. So I opened logs and found below Line in Log based on Co relation ID.
01/29/2013 09:46:44.72 w3wp.exe (0x01F0) 0x1D9C SharePoint Foundation Runtime tkau Unexpected System.NullReferenceException: Object reference not set to an instance of an object. at Microsoft.SharePoint.ApplicationPages.UploadPage.OnLoad(EventArgs e) at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) 548fc865-0319-4279-b1da-2b35d0a47996