"Object reference not set to an instance of an object" when open a document library in Site Content and structure.
Hi all
I meet a problem when I try to open a document library in site content and structure, it gives me a errorinformation like below
Object reference not set to an instance of an object. at Microsoft.SharePoint.Publishing.Internal.WebControls.ToolbarViewSelectionDropdown.CreateChildControls()
at System.Web.UI.Control.EnsureChildControls()
at Microsoft.SharePoint.Publishing.Internal.WebControls.ToolbarDropdown.OnLoad(EventArgs e)
at Microsoft.SharePoint.Publishing.Internal.WebControls.ToolbarViewSelectionDropdown.OnLoad(EventArgs e)
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.AddedControl(Control control, Int32 index)
at Microsoft.SharePoint.Publishing.Internal.WebControls.Toolbar.Add(ToolbarObject objItem)
at Microsoft.SharePoint.Publishing.Internal.States.SmtState.AddViewSelectionButton(Toolbar toolbar, String script)
at Microsoft.SharePoint.Publishing.Internal.States.SmtState.AddButton(Toolbar toolbar, String operation, String script)
at Microsoft.SharePoint.Publishing.Internal.States.SmtState.AddButton(Toolbar toolbar, String operation)
at Microsoft.SharePoint.Publishing.Internal.States.SmtState.initToolbarForErrorHandling(Toolbar toolbar)
at Microsoft.SharePoint.Publishing.Internal.States.SmtState.ConfigureForErrorHandling(SMObjectList objectlist)
at Microsoft.SharePoint.Publishing.Internal.States.SmtState.HandleErrors(SMObjectList objlist, Exception ex)
at Microsoft.SharePoint.Publishing.Internal.States.SmtDocLibItemState.Configure(SMObjectList objectlist)
at Microsoft.SharePoint.Publishing.Internal.WebControls.SMObjectList.Handle_LoadCompleteEvent(Object sender, EventArgs e)
at System.EventHandler.Invoke(Object sender, EventArgs e)
at System.Web.UI.Page.OnLoadComplete(EventArgs e)
at Microsoft.SharePoint.WebControls.LayoutsPageBase.OnLoadComplete(EventArgs e)
at Microsoft.SharePoint.Publishing.Internal.CodeBehind.SmtMainPage.OnLoadComplete(EventArgs e)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)


When I try to open other library or list, it works fine. Does anyone meet it before?


Best Regards
August 26th, 2009 7:57am

Hi,

Which version is your SharePoint?

Open your SharePoint site, and click the problematic document library, what is the result?

May I know if the issue persists when we login the site as the site collection administrator?

May I know if the document library or the folder that you want to open inherit from parent? If not, please grant the user same permissions for the library. And check the effect.

If you convert a document library to xslt in SPD, save that modification and try to access the document library via content and structure , then you receive this error, you can try the following steps:

1). Create a new site definition to overwrite the default behavior of a Document Library. Here is the article describing how to achieve this:

Creating a Site Definition from an Existing Site Definition

http://msdn.microsoft.com/en-us/library/ms868598.aspx

2). Create a new page and embed the Document Library web part. (one can do all the modifications needed in there)

If the steps above cant resolve your issue, please enable ULS log, and reproduce the issue, send the error information into the forum for analyze.

Hope it can be helpful for you.

Rock Wang

Free Windows Admin Tool Kit Click here and download it now
August 28th, 2009 6:39am

Hi,

Even I faced the same problem, if I try to open the document library from site content and structure Im getting "object reference not set" error but can able to open the other document libraries and lists which is having same settings as the faulty one.

I checked the permissions everything is perfect, but not sure why its not working in site content and structure.

Any help would be appreciated.
February 26th, 2010 12:44pm

HI,

Create new view with default fields and set this view as default view than open document library from site content and structure if it works than issue may be because of custom field.

I have same issue and it is because of one custom field if I remove this field than it works fine.

Hope this will help you.

Free Windows Admin Tool Kit Click here and download it now
May 22nd, 2010 10:06am

Hi,

I'm having the same issue...All other document library in the same site is working fine..

One of the Document library in the site, works fine if I try to open the document library from View All Site Content

But shows the following error if I try to open a document library in site content and structure


Object reference not set to an instance of an object.   at Microsoft.SharePoint.Publishing.Internal.WebControls.ToolbarViewSelectionDropdown.CreateChildControls()
   at System.Web.UI.Control.EnsureChildControls()
   at Microsoft.SharePoint.Publishing.Internal.WebControls.ToolbarDropdown.OnLoad(EventArgs e)
   at Microsoft.SharePoint.Publishing.Internal.WebControls.ToolbarViewSelectionDropdown.OnLoad(EventArgs e)
   at System.Web.UI.Control.LoadRecursive()
   at System.Web.UI.Control.AddedControl(Control control, Int32 index)
   at Microsoft.SharePoint.Publishing.Internal.WebControls.Toolbar.Add(ToolbarObject objItem)
   at Microsoft.SharePoint.Publishing.Internal.States.SmtState.AddViewSelectionButton(Toolbar toolbar, String script)
   at Microsoft.SharePoint.Publishing.Internal.States.SmtState.AddButton(Toolbar toolbar, String operation, String script)
   at Microsoft.SharePoint.Publishing.Internal.States.SmtState.AddButton(Toolbar toolbar, String operation)
   at Microsoft.SharePoint.Publishing.Internal.States.SmtState.initToolbarForErrorHandling(Toolbar toolbar)
   at Microsoft.SharePoint.Publishing.Internal.States.SmtState.ConfigureForErrorHandling(SMObjectList objectlist)
   at Microsoft.SharePoint.Publishing.Internal.States.SmtState.HandleErrors(SMObjectList objlist, Exception ex)
   at Microsoft.SharePoint.Publishing.Internal.States.SmtDocLibItemState.Configure(SMObjectList objectlist)
   at Microsoft.SharePoint.Publishing.Internal.WebControls.SMObjectList.Handle_LoadCompleteEvent(Object sender, EventArgs e)
   at System.EventHandler.Invoke(Object sender, EventArgs e)
   at System.Web.UI.Page.OnLoadComplete(EventArgs e)
   at Microsoft.SharePoint.WebControls.LayoutsPageBase.OnLoadComplete(EventArgs e)
   at Microsoft.SharePoint.Publishing.Internal.CodeBehind.SmtMainPage.OnLoadComplete(EventArgs e)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

I tried creating a new view with default columns, but still no luck. Can anyone help on this?

 

  • Proposed as answer by sjdavies Thursday, July 05, 2012 7:39 AM
  • Unproposed as answer by sjdavies Thursday, July 05, 2012 7:39 AM
June 10th, 2010 10:12pm

You, sir, are my hero today. I had a survey where I needed to delete the results, and could no longer do so. I had modified the survey results pages Overview.aspx, AllItems.aspx, Summary.aspx. After creating a brand new "Temp.aspx" and copying in the ViewFields fields from one of the other .aspx views, it worked fine.
Free Windows Admin Tool Kit Click here and download it now
March 27th, 2013 7:53pm

I tried creating a view with only "Name" column alone and made that as default view. Even then I am getting the same error.My Library is connected to two custom content type (1 is Document Set as parent content type, another one is Document as parent content type). 

I thought problem with content types. I created a test library in the same site and attached those 2 content type towards it, But I am able to view that library from Site Content and Structure.

Please let me know if there is any workaround to fix this


  • Edited by sivambe 10 hours 24 minutes ago
March 6th, 2015 5:04pm

I tried creating a view with only "Name" column alone and made that as default view. Even then I am getting the same error.My Library is connected to two custom content type (1 is Document Set as parent content type, another one is Document as parent content type). 

I thought problem with content types. I created a test library in the same site and attached those 2 content type towards it, But I am able to view that library from Site Content and Structure.

Please let me know if there is any workaround to fix this


  • Edited by sivambe Friday, March 06, 2015 10:03 PM
Free Windows Admin Tool Kit Click here and download it now
March 6th, 2015 10:03pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics