Set custom field value in ItemAdding event

Installing SharePoint 2010

Follow the link below to install SharePoint 2010:

Setting Up the Development Environment for SharePoint 2010 on Windows Vista, Windows 7, and Windows Server 2008

You may find this video useful as well if you are installing SharePoint 2010 on Windows 7.

If you have got any error while installing; it is most likely because of you might have missed some prerequisite. So read the msdn article properly and let me know if you need any help.

If you got above error then you have not installed .net framework 3.5 which is mentioned for prerequisite for SharePoint 2010.

If you got above error then the MSSQL$SharePoint database service has not been created so to resolve this you could try repair option.

Go to control panel -> add/remove program -> choose SharePoint  -> right-click and select Repair.

For them who want to use local administrator account for central administration

During initial installation you will need to use domain administrator account: like domain\UserLoginname
Later on you can configure to use local admin account.
for more detail please read this post:

Happy Installing 🙂

Add/remove content type to SharePoint List

In this post I will discuss about how to add/remove content type to and from SharePoint list.

Add/remove Content type in SharePoint Designer:

when you open a list in SPD you will find Content Types section as shown in the figure below.

Once you select content type region you will find content type actions in the ribbon as well.

Add/remove content type programmaticaly:

In code I have removed “Folder” content type and added “Image” content type to the list. And so it should look like this in SharePoint designer.

Hope that helps…!!