.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal

Home >> Articles >> SharePoint >> Post New Resource Bookmark and Share   

 Subscribe to Articles

Content Type in SharePoint Tutorial

Posted By:Dhananjay Kumar       Posted Date: January 01, 2010    Points: 25    Category: SharePoint    URL: http://www.dotnetspark.com  

Content Type in SharePoint Tutorial


In this article, I am going to give and walkthrough of how to define a custom Content type in MOSS or SharePoint.

Step 1:

Go to Site Setting of the root site. Click on Site Action then select Site Setting.


Step 2:

From the Galleries section select Site content types.


Step 3:

In Site Content Type Gallery, select Create option.


Step 4:

I will define a new type called Press Content here.  The values for different fields, I am giving as below.

Name: Press Content
Description:  This is a new content type associate with the documents.
Parent Content type form: Document Content Types
Parent Content Type: Document
Group: Existing Group (Custom Content Type)


Step 5:

The new content type will have only one property called Title property.  I will expand the properties by adding new columns.

The new properties, I will be adding as below 

  1. Subtitle as Single Line of text and it would be an optional property.
  2. Publish Date as date and time and it would be optional property.
  3. PR Contact as Person or Group and it would be optional property.

To add new column from the column group select Add from New site columns 


Step 6:

To see how to add new site column, see my other articles on this site. After adding all the columns , the column group will look like below.


Step 7:

Now I will update the Document Template. I will pull the Content type Meta data into uploaded document template.

To do this click on Advance setting in the Setting group inside Press Release Content type.


Create a blank word document and save it. Browse to that document in upload the new document template section. Leave for other field the default values.


Step 8:

Up to this step I have created the custom content type. Now I am going to attach this content type to a document library.

To attach go to advance setting of document library go to Document Library setting from setting. From General Setting go to advance setting. 



Select Allow Management of Content type Yes and leave other filed with default values.


Step 9:

Inside Setting of document library, go to Content Types group. Here select  Add From existing site contents.


Select the newly created content type and click ADD button.


Step 10:

Go to Document library. While adding new item new document template with metadata of content type would be available there.



In this article, I have shown how to create a new custom content type. Thanks for reading.

Happy Coding

 Subscribe to Articles


Further Readings:


No response found. Be the first to respond this post

Post Comment

You must Sign In To post reply
Find More Articles on C#, ASP.Net, Vb.Net, SQL Server and more Here

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend