SyncronizedEPTDocumentGetMetaFieldAsInteger Method Content Studio 5.7 SDK
Content Studio Web Content Management System

[This is preliminary documentation and is subject to change.]

Returns the value, as an Int32, of a specified Content Studio meta data field that exists for every EPT document.

Namespace: ContentStudio.Document.EPT
Assembly: CSServer5 (in CSServer5.dll) Version: 5.7.5016.0 (5.7.5016.0)
Syntax

public int GetMetaFieldAsInteger(
	string fieldName
)

Parameters

fieldName
Type: SystemString
The name of the field. This name must start with CSMetaDataPrefix or WFMetaDataPrefix.

Return Value

Type: Int32
The value of the field if found, -1 if the field does not exist.
Exceptions

ExceptionCondition
ArgumentNullExceptionThe argument FieldName cannot be null.
ArgumentExceptionThe argument FieldName must start with either CSMetaDataPrefix or WFMetaDataPrefix.
FormatExceptionThe value cannot be converted to an integer (i.e. the field value does not consist solely of an optional negative sign followed by a sequence of digits ranging from 0 to 9).
OverflowExceptionThe field value represents a number less than MinValue or greater than MaxValue.
Remarks

This method returns -1 if schema binding is off and for documents created with this class even if they are saved and published. In order to read the meta data fields given for a created document you must reload it.
See Also

Reference