property MaskEdit.Mask as String
Retrieves or sets a string expression that indicates the control's mask.

 TypeDescription 
   String A string expression that indicates the control's mask  
Indicates the control's mask. Use the MaskValue property to get the value entered, and use the Valid property to check the value's validity. Use the Masks property to provide multiple masks to the control. Use the MaskFloat property to mask floating point numbers without displaying the masking character. The MaskChange event is fired when the Mask property is changed. The Mask property is composed by a combination of regular characters, literal escape characters, and masking characters. The Mask property can contain also alternative characters, or range rules. A literal escape character is preceded by a \ character, and it is used to display a character that is used in masking rules. 

Here's the list of all rules and masking characters.

The following sample shows how to mask an IP address:

MaskEdit1.Mask = "{0,255}\.{0,255}\.{0,255}\.{0,255}"

Send comments on this topic.
© 1999-2007 Exontrol Inc, Software. All rights reserved.