AquaLogic Interaction Development Kit (IDK) 6.0.0 |

# IContentItemManager.CreateContentItem Method

Creates a new `IContentItem` with the given `IDataEntryTemplate` in the containing folder.

IContentItem CreateContentItem(
IFolder containingFolder,
string name,
IDataEntryTemplate dataEntryTemplate
);

#### Parameters

containingFolder
  The folder the `IContentItem` will be created in; cannot be `null`.
name
  The name of the content item; cannot be `null`, empty, or longer than 255 characters. The string used for the name will be trimmed of leading and trailing whitespace when it is stored and is case-insensitive during name comparison.
dataEntryTemplate
  The `IDataEntryTemplate` used for the content item; cannot be `null`.

#### Return Value

An `IContentItem` that has not been persisted. `IContentItemManager.`CheckInItem must be called to persist the item.

#### Remarks

This method does not create a persistent object. To create and persist a content item use this method to create a new item, then use `IContentItem.SetPropertyValue` to set the property values, and `IContentItemManager.CheckInItem` to persist the item.

The containing folder and the Data Entry Template must be persisted prior to calling this method otherwise an `InvalidOperationException` will be thrown.

#### Exceptions

Exception Type | Condition
--- | ---
InvalidOperationException | The specified folder or the Data Entry Template has not been stored or has already been removed.
ArgumentException | The name is an empty string or longer than 255 characters.

#### See Also

IContentItemManager Interface | Plumtree.Remote.PRC.Content.Item Namespace