Methods | ScriptContext.CreateField(String) Method
Creates a new field with a Text FieldItemType.
Syntax
C#
Copy
public FieldItem CreateField(
string fieldName
)
Parameters
fieldName String
Name of the field to create.
Return Value
FieldItem
The created FieldItem instance.
Implements
IScriptContext.CreateField(String)
Exceptions
| Exception | Condition |
|---|---|
| ArgumentNullException | Thrown if fieldName is null or empty. |
| ArgumentException | Thrown if the fieldName already exists. |
Remarks
Defaults the field's type to Text
See Also
Reference
ScriptContext Class
CreateField Overload
Compiled.EDD.Scripting Namespace