Method SetValue
SetValue(string)
Fills the field in: updates the stored state and the displayed result together.
public void SetValue(string value)
Parameters
valuestringThe new value.
Remarks
A check box takes a boolean. A drop-down takes one of its entries, matched ordinally, and is refused anything else — Word does not allow a value outside the list. A text field takes any text, truncated to MaxLength when one is set, because Word will not accept more than it declared.
Exceptions
- ArgumentNullException
valueis null.- FormFieldEditException
The value is not valid for the field's kind, or the preserved markup could not be rewritten.