FormFieldResult Property |
Namespace: Aspose.Words.Fields
For a text form field the result is the text that is in the field.
For a checkbox form field the result can be "1" or "0" to indicate checked or unchecked.
For a dropdown form field the result is the string selected in the dropdown.
Setting Result for a text form field does not apply the text format specified in TextInputFormat. If you want to set a value and apply the format, use the SetTextInputValue(Object) method.
Document doc = new Document(MyDir + "Form fields.docx"); FormField formField = doc.Range.FormFields[3]; if (formField.Type.Equals(FieldType.FieldFormTextInput)) formField.Result = "My name is " + formField.Name;