public class RegularExpressionValidator extends BaseValidator implements com.aspose.ms.System.ICloneable
Makes the associated input control a required field.
[C#] Pdf pdf1 = new Pdf(); Aspose.Pdf.Generator.Section Section1 = pdf1.Sections.Add(); FormField textBox = new FormField(); textBox.FormFieldType = FormFieldType.Text; textBox.FieldName = "AText"; textBox.FormWidth = 80; textBox.FormHeight = 20; RegularExpressionValidator validator = new RegularExpressionValidator(); validator.ValidationExpression = "^[0-9]+$"; validator.ErrorMessage = "Value does not match validation expression"; textBox.Validators.Add(validator); Section1.Paragraphs.Add(textBox); pdf1.Save(...);
Constructor and Description |
---|
RegularExpressionValidator() |
Modifier and Type | Method and Description |
---|---|
Object |
deepClone()
Clones a new
RegularExpressionValidator object. |
String |
getValidationExpression()
Gets or sets the regular expression that determines the pattern used to validate a field.
|
void |
setValidationExpression(String value) |
getErrorMessage, setErrorMessage
public String getValidationExpression()
Gets or sets the regular expression that determines the pattern used to validate a field.
public void setValidationExpression(String value)
public Object deepClone()
Clones a new RegularExpressionValidator
object. This method clones only the format but not contents of the cell.
deepClone
in interface com.aspose.ms.System.ICloneable
deepClone
in class BaseValidator
RegularExpressionValidator
object.Copyright © 2016 Aspose. All Rights Reserved.