| | | | | | | | | |
|
|
|
|
|
|
|
|
| |
1.1 ASP.NET CompareValidator Control Properties
« Previous Chapter
Next Chapter » |
|
|
| |
In the previous chapter you learnt an ASP.NET tutorial on how to use ASP.NET CompareValidator Control. The following are some of the important attributes/properties used together with the ASP.NET CompareValidator Control.
Property |
Description |
BackColor |
Property to set the background color for the Control |
ControlToCompare |
Property to set the name of the ASP.NET Control to Compare to |
ControlToValidate |
Property to set the id of the ASP.NET Control to validate |
Display |
Property to set the display behavior for the ASP.NET validation control.
- None – does not display the validation and only displayed in the ASP.NET ValidationSummary control.
- Static – displays the validation message if check fails. The space of the control is reserved even if the check passes.
- Dynamic – displays the validation message if check fails. The space of the control is not reserved if the check passes.
|
EnableClientScript |
Property to set a Boolean value to specify if client-side validation is enabled or disabled. |
Enabled |
Property to set a Boolean value to specify if validation control is enabled or disabled. |
ErrorMessage |
Property to set the Validation text to be displayed in the ValidationSummary Control when the validation check fails. Even if the text property is not set, the default text will be displayed in the validation control. |
ForeColor |
To set the foreground color of the ASP.NET CompareValidator Control |
id |
A unique ID for the ASP.NET CompareValidator Control |
IsValid |
Property to set a Boolean value to indicate if the control specified by ControlToValidate is determined to be valid. |
Operator |
To set the type of comparison to perform:
- Equal
- GreaterThan
- GreaterThanEqual
- LessThan
- LessThanEqual
- NotEqual
- DataTypeCheck
|
runat |
To indicate that the Control is a server control (by setting it to “server”) |
Text |
To set the validation text message to be displayed when check fails. |
Type |
To set the data type of the values to compare:
- Currency
- Date
- Double
- Integer
- String
|
ValueToCompare |
To set the value to compare with. |
« Previous Chapter
Next Chapter »
Table of Contents
Chapter 1 - ASP.NET CompareValidator Control
» Chapter 1.1 - ASP.NET CompareValidator Control Properties
Chapter 2 - ASP.NET CustomValidator Control
Chapter 2.1 - ASP.NET CustomValidator Control Properties
Chapter 3 - ASP.NET RangeValidator Control
Chapter 3.1 - ASP.NET RangeValidator Control Properties
Chapter 4 - ASP.NET RegularExpressionValidator Control
Chapter 4.1 - ASP.NET RegularExpressionValidator Control Properties
Chapter 5 - ASP.NET RequiredFieldValidator Control
Chapter 5.1 - ASP.NET RequiredFieldValidator Control Properties
Chapter 6 - ASP.NET ValidationSummary Control
Chapter 6.1 - ASP.NET ValidationSummary Control Properties
[top] |
|
| |
|
|
| | |
|
|
|