SEARCH
0-9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Prev | Current Page 235 | Next

Robin Pars, Laurence Moroney, and John Grieb

"Foundations of ASP.NET AJAX"

This guarantees that invalid
data cannot be passed on from the text box (excluding HTTP data injection or other
advanced malicious attempts). The main properties of the FilteredTextBox extender are
listed in Table 8-3.
Table 8-3. FilteredTextBox Extender Properties
Property Name Description
FilterMode If the selected FilterType property is Custom, FilterMode can be either
InvalidChars or ValidChars.
FilterType Type of filter to be applied to the target TextBox (can be more than one
value separated by a comma). Potential values are Numbers,
LowercaseLetters, UppercaseLetters, and Custom.
InvalidChars When FilterType is set to Custom, and FilterMode is set to
InvalidChars, this property can contain a list of all invalid characters.
TargetControlID ID of the target TextBox control.
ValidChars When FilterType is set to Custom, and FilterMode is set to ValidChars,
this property can contain a list of all valid characters.
For instance, if you want an input box that only accepts digits, you can use this extender
with the FilterType property set to Numbers to prevent the user from entering any other
nonnumeric characters as shown in the following code snippet and in Figure 8-4.


Pages:
223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247