Contents tagged with exception

  • Sharepoint 2010 Tip: Exception When Editing Pages - MediaWebPart and NullReference

    Had a confusing bug in a stage environment today where you could create pages (such as the inbuilt Article Page), but when you went to edit them it would through an exception: System.NullReferenceException: Object reference not set to an instance of an object. at Microsoft.SharePoint.Publishing.WebControls.MediaWebPart.get_WebPartAdderId() at Microsoft.SharePoint.Publishing.WebControls. … more

  • SharePoint Gotcha: Working with change tokens and change logs

    Was working on some code today, which was a timer job that used to work, but now doesn't. In the timer job, we had essentially something similar to the following: SPChangeToken changeToken = list.ParentWeb.Properties["mychangetoken"]; SPChangeCollection changedItems = null; SPChangeQuery queryitem = new SPChangeQuery(false, true); queryitem.Item = true; … more

  • Pro-Tip: Connecting To SharePoint Online / Office 365 from an Azure Web / Worker Role

    Today, I was tasked with debugging an issue someone at work had been having - we've built some stuff that needs to connect to a SharePoint Online instance from within an Azure Worker role, and whilst it worked locally, when it was run in the cloud, it continually caused the role to error out. To connect, we're grabbing the claims-based cookies (for which you can read Chris Johnson's post about … more

  • VS2010 SharePoint Projects: Error occurred in deployment step 'Add Solution'

    The inbuilt Visual Studio 2010/Sharepoint 2010 tooling has improved significantly since the WSS 3.0 days, but there are still quite a few annoyances that crop up from time to time. One error which you might encounter is the following, when you are attempting to deploy what is otherwise a perfect solution: Error occurred in deployment step 'Add Solution': Value cannot be null. Parameter name: s … more

  • 1