Monthly Archives: June 2010

Constructor on type ‘Microsoft.SharePoint.SPFieldCalculated’ not found – and the weird SharePoint API

Observed in: SharePoint 2007 and SharePoint 2010. Today I was writing some code to add an SPFieldCalculated column to a list. I got the error message Constructor on type ‘Microsoft.SharePoint.SPFieldCalculated’ not found. when calling SPFieldCollection.CreateNewField(fieldType.ToString(), displayName) This call was working … Continue reading

Posted in SharePoint, SPFieldCalculated | Leave a comment

The mysterious SPItemEventProperties.AfterProperties

What you can/cannot access in BeforeProperties and AfterProperties in list event receivers can be mysterious. Here is a very good/clear description of what you can expect when and where: In addition to what’s in the above link, I found that … Continue reading

Posted in SharePoint | Leave a comment

Can’t create SPSite object in SharePoint 2010: FileNotFoundException: The Web application at http://localhost could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application.

I wrote my first console app against SP2010 in VS2010 the other day and ran into the above exception at the very first line: using (SPSite site = new SPSite(http://localhost) It turns out because my console app was targeting x86 … Continue reading

Posted in SharePoint | 2 Comments

Upload Multiple Documents in SharePoint stops working with Office 2010 clients

Problem: Uploading Multiple Documents into a Document Library in SharePoint doesn’t work on client machines with Office 2010 installed. You are able to drag & drop or browse for files, but when you click OK, the spinning icon just spins forever … Continue reading

Posted in Office 2010, SharePoint | 1 Comment

Changing custom timer job schedule in SharePoint 2010

Well actually this is really easy to do now in SharePoint 2010. In Central Admin, go to Monitoring > Review job definitions > [job] and you get the setting screen below.   Notice that there is also a RUN NOW … Continue reading

Posted in SharePoint | Leave a comment

Can’t retract SharePoint timer job because the job "cannot be deserialized because it does not have a public default constructor"

If you forgot to include a default constructor in your timer job class, you will get the error below when activating the feature that installs the job: SharePointProject1.TimerJobs.TrackingTimerJob cannot be deserialized because it does not have a public default constructor. … Continue reading

Posted in SharePoint | Leave a comment

Properties missing from Visual Studio 2010 Intellisense..

Today I ran into a problem that made me think I was either blind, crazy.. or both. I created a new SharePoint 2010 project in Visual Studio 2010 and was trying to code against the SPSite.WebApplication property but it was … Continue reading

Posted in SharePoint, Visual Studio 2010 | Leave a comment