SP_SetContentType

Sets the type of content in the SharePoint library for the uploaded documents, such as an Invoice.

Syntax

bool SP_SetContentType(StrParam)

Parameters

A valid SharePoint content type in the selected Library. No error is raised if it is not a valid content type. Smart Parameters are supported.

Returns

True if the content type was successfully set or if the content type is not a valid content type. False if there is failure returned from SharePoint.

Level

All.

Details

This action sets the SharePoint Content Type for each document that is subsequently uploaded. Content Type is a SharePoint concept that defines a subset of columns (fields) within a library of documents, to be displayed and edited for a specific purpose.
Example
SP_SetContentType("Invoice")