<img height="1" width="1" style="display:none;" alt="" src="https://px.ads.linkedin.com/collect/?pid=6889170&amp;fmt=gif">
Skip to content
  • There are no suggestions because the search field is empty.

Methods | DocumentItem.TryGetFieldData Method

Attempts to get the field data from the document matching the type param. If the field data is not set, false is returned, and fieldData is set to default(T). If the field has data, and matches the type, true is returned, with fieldData set to the value.

Syntax

C# Copy
public bool TryGetFieldData<T>(
	FieldItem field,
	out T fieldData
)

Parameters
field    FieldItem
           The field to retrieve a value for.
fieldData    T
           The field value matching the type param.

Type Parameters
T
           Only string, int, float, DateTime or bool should be specified here.

Return Value
Boolean
true if value retrieved matching type successfully; otherwise false.

Exceptions

Exception Condition
ArgumentNullException Thrown if field param is null.

See Also

Reference
DocumentItem Class
Compiled.EDD.Scripting Namespace