IScriptContextGetOrCreateField(String, ChoiceFieldItemType) Method |  |
Gets or creates the field matching both the given name and choice type.
Namespace: Compiled.EDD.ScriptingAssembly: Compiled.EDD.Scripting (in Compiled.EDD.Scripting.dll) Version: 9.0.0.0-142fa9725
SyntaxFieldItem GetOrCreateField(
string fieldName,
ChoiceFieldItemType choiceFieldItemType
)
Parameters
- fieldName String
- The name of the field.
- choiceFieldItemType ChoiceFieldItemType
- The choice type of the field.
Return Value
FieldItemThe existing field if the field exists and matches the choice type; otherwise, the newly created field.
Exceptions| Exception | Condition |
|---|
| Exception | Thrown when a matching field name exists but the choice type does not match the field type. |
See Also