--- title: "Content Types for Document Templates" slug: "content-types-for-document-templates" description: "The article describes creating the Employee Documents library content types based on which you set up templates for generating employee documents. " updated: 2024-02-29T14:36:52Z published: 2024-02-29T14:36:52Z canonical: "help.lanteria.com/content-types-for-document-templates" --- > ## Documentation Index > Fetch the complete documentation index at: https://help.lanteria.com/llms.txt > Use this file to discover all available pages before exploring further. # Content Types for Document Templates Use content types to create templates for generating employee documents or job contracts. A template can contain automatic fields from the content type that are filled in with the employee data in the generated document. The article describes creating content types for the **Employee Documents** library. In the same way, they can be created for the **Job Contracts** library. ## Create Content Type Follow these steps to create a new content type: 1. Under **Setting** > **SharePoint Settings** > **Web Designer Galleries**, click **Site content types**.![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img881.png) 2. Next, click **Create**. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img882.png) 3. Provide the content type name and description. 4. Select a group from which parent content type will be selected. Then select a parent content type the current type will be based on. The initial set of fields for content type will be taken from the parent type. 5. Select a group the content type will belong to (select an existing group or create a new one).![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img884.png) 6. Click **OK** to save your content type. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img883.png) ## Add Content Type to Doc Library The next step is to add the newly created content type to a document library it will be used for. 1. Go to **Settings** > **Site Lists and Libraries** and locate the document library the content type will be added to. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img885.png) 2. Click the library name and on the page that opens, click the **Library** tab and then **Library Settings**. 3. Next, click **Add from existing site content types**. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img887.png) 4. Select the previously created type and click **Add**. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img887(1).png) 5. Click **OK**. The content type will be added to the library. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img888.png) ## Add Fields to Content Type After the content type has been added to the document library, add fields to it. 1. In the document library settings, under **Content Types**, click the name of the created content type. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img888(1).png) 2. On the page that opens, click **Add from existing site or list columns**.![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img890.png) 3. Select the columns to be used for content type (you'll be able to add them as automatic fields to your document templates) and click **Add** and then **OK**.![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img891.png) ### Add New Columns to Doc Library If the columns you would like to add are missing in the document library, add them to the library. Any columns from the **Employees** and **Salary Details** lists can be added. To add a column, follow these steps: 1. First of all, you'll need the internal name of the column you'll be adding, since it is specified when creating a column. To check it, open the **Employees** (or **Salary Details**) list from **Settings** > **Site Lists and Libraries** and click the name of the column you'll be adding. The address bar will contain its internal name. Copy it. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img893(1).png) 2. Return to the **Employee Documents** library settings (**Settings** > **Site Lists and Libraries** > **Employee Documents** and on the **Library** tab, click **Library Settings**). Next, click **Create column**. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img892.png) 3. In the **Column name** field, paste the the internal name you copied. If you are adding a lookup field and want the field value instead of ID to be displayed on your documents, type **_Value** after the column name and set the column type to **Single line of text**. For example, if you add the **Employee** field and in the **Column name**, specify **Employee**, the employee ID will be displayed in the documents where it is used as automatic field. If you add **Employee_Value**, the employee name will be displayed. For the fields of the other types, just type in the internal name and select the column type as in the original list.![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img894.png) 4. Click **OK**. If the **Add to all content types** check box is selected, the column will be added to your content type automatically. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img895.png) 5. Make sure that all the required columns have been added to the content type (for **Employee Documents**, it is **Employee**, **Document Type**, **Employee Access**, **Manager Access**). ## Create Document Template Now it's time to create a document template and insert the content type columns as automatic fields to be filled in with data in the generated documents. 1. In the content type settings (under **Settings** > **Site Lists and Libraries** select **Employee Documents** and click **Library** > **Library Settings**, under **Content Types**, click the content type name), click **Advanced settings**.![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img896.png) 2. Click **Upload a new document template**, browse for a file to be used as template and click **OK**. Please note that template must be in the .docx format. Next, click **Edit Template** to add automatic fields to the uploaded file. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img904.png) 3. Next, click **Edit Template**. 4. When the template opens, click **Insert** > **Quick Parts** > **Document Property** and select a field to be inserted.![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img899.png) 5. In the same way, insert all the fields you want to be automatically filled in. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img900.png) 6. Save the template. ## Generate Document based on Template When the template is ready, the documents can be generated based on it. 1. Open an employee card and click **Documents**. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img901.png) Select the content type you created and click **Generate**. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img902.png)The file will be generated.![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img905.png) and automatic fields filled in. ![](https://cdn.document360.io/c315c68d-2799-4fcc-9a39-084315b58f14/Images/Documentation/img906.png)