Creating a Content Type for the Timesheet InfoPath Form
In previous tutorials I showed you how to create a Departments list and custom lookup column that uses the Departments list as its data source for the dropdown values. In the first article, I mentioned I was going to show you how to create an InfoPath form to allow users to submit their time and then use a workflow to validate and approve the time submission. In this tutorial, I will illustrate how to create a content type that will be used to store data for the Timesheet InfoPath form.
A Content Type is a SharePoint object that contains columns that are used to describe a specific piece of content, such as a Timesheet entry. Out of the box content types include Document, Item, Event and Contact, for example. Content types can be created at various levels within a SharePoint site hierarchy including the Site Collection and Site level. The higher up the hierarchy the content type resides, the broader the scope in which it can be used. Since content types are objects, workflows can check for specific content types or create a workflow for a specific content type.
Our Timesheet content type is going to have the following columns:
I will show you how to create the Notes column. After that, to avoid repetitive steps, I will give you a table of values for the remaining columns and let you create them using the steps for the Notes field.
You will need to navigate to the same location where the departments column was created, which should be the root of your site collection. My departments list and custom column are at the root of my training site.
Creating Timesheet Content Type
Here are the steps to create the Timesheet content type and the Notes column:
Here are the list of columns that you should have after you complete this step.
Let's organize the fields in the order that they will appear in our timesheet. Below is a sneak peek at the form we will build in future articles. As you can see, the columns are not in the correct order.
That it! You've created the Timesheet content type.
Here are the screenshots of the columns you created in this article for your reference:
Author: Eric Stepek, one of Accelebrate’s SharePoint instructors