'Declaration Public Event InvalidChar As EventHandler(Of InvalidCharEventArgs)
public event EventHandler<InvalidCharEventArgs> InvalidChar
The event handler receives an argument of type InvalidCharEventArgs containing data related to this event. The following InvalidCharEventArgs properties provide information specific to this event.
Property | Description |
---|---|
Beep | Gets or sets a value indicating whether the XamMaskedInput should beep. |
Char | Gets the invalid character that the user attempted to input. |
DisplayChar | Gets the display character instance where the user attempted to enter the invalid character. |
The InvalidChar event is fired when user types a character that does not match the mask associated with the current input position.
Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2