Class
RegexMaskTextBoxProvider

Definition

Namespace:Telerik.WinControls.UI

Assembly:Telerik.WinControls.UI.dll

Syntax:

cs-api-definition
public class RegexMaskTextBoxProvider : IMaskProvider

Inheritance: objectRegexMaskTextBoxProvider

Derived Classes: EMailMaskTextBoxProvider

Implements: IMaskProvider

Constructors

RegexMaskTextBoxProvider(string, CultureInfo, RadMaskedEditBoxElement)

Initializes a new instance of the RegexMaskTextBoxProvider class.

Declaration

cs-api-definition
public RegexMaskTextBoxProvider(string mask, CultureInfo culture, RadMaskedEditBoxElement owner)

Parameters

mask

string

The mask.

culture

CultureInfo

The culture.

owner

RadMaskedEditBoxElement

The owner.

Fields

regex

Declaration

cs-api-definition
protected Regex regex

Field Value

Regex

Properties

AllowEmptyString

Gets or sets a value indicting whether empty strings are valid.

Declaration

cs-api-definition
public bool AllowEmptyString { get; set; }

Property Value

bool

Culture

Gets the culture that determines the value of the localizable separators and placeholders in the input mask.

Declaration

cs-api-definition
public CultureInfo Culture { get; }

Property Value

CultureInfo

A System.Globalization.CultureInfo containing the culture information associated with the input mask.

Implements IMaskProvider.Culture

ErrorMessage

Gets or sets the error message.

Declaration

cs-api-definition
public string ErrorMessage { get; set; }

Property Value

string

ErrorProvider

Gets or sets the error provider.

Declaration

cs-api-definition
public ErrorProvider ErrorProvider { get; set; }

Property Value

ErrorProvider

IsValid

Gets a value indicating whether the text matches the regular expression created using the Mask Sets an error if there is no match and is true.

Declaration

cs-api-definition
public bool IsValid { get; }

Property Value

bool

Mask

Gets the input mask.

Declaration

cs-api-definition
public string Mask { get; }

Property Value

string

A string containing the full mask.

Implements IMaskProvider.Mask

TextBoxItem

Gets the text box item.

Declaration

cs-api-definition
public RadTextBoxItem TextBoxItem { get; }

Property Value

RadTextBoxItem

Implements IMaskProvider.TextBoxItem

Value

Gets or sets the value.

Declaration

cs-api-definition
public object Value { get; set; }

Property Value

object

Implements IMaskProvider.Value

Methods

Clone()

Clones this instance.

Declaration

cs-api-definition
public IMaskProvider Clone()

Returns

IMaskProvider

The cloned instance.

Implements IMaskProvider.Clone()

KeyDown(object, KeyEventArgs)

Occurs when a key is pressed.

Declaration

cs-api-definition
public void KeyDown(object sender, KeyEventArgs e)

Parameters

sender

object

The sender.

e

KeyEventArgs

Key event arguments.

Implements IMaskProvider.KeyDown(object, KeyEventArgs)

KeyPress(object, KeyPressEventArgs)

Occurs when a key is pressed.

Declaration

cs-api-definition
public void KeyPress(object sender, KeyPressEventArgs e)

Parameters

sender

object

The sender.

e

KeyPressEventArgs

Key event arguments.

Implements IMaskProvider.KeyPress(object, KeyPressEventArgs)

ToString(bool, bool)

Returns the formatted string.

Declaration

cs-api-definition
public string ToString(bool includePrompt, bool includeLiterals)

Parameters

includePrompt

bool

Not used.

includeLiterals

bool

Not used.

Returns

string

The formatted System.String that includes all the assigned character values.

Implements IMaskProvider.ToString(bool, bool)

UnwireEvents()

Detaches from events.

Declaration

cs-api-definition
public void UnwireEvents()

Validate(string)

Validates the given string value and applies it as if the value is valid.

Declaration

cs-api-definition
public bool Validate(string value)

Parameters

value

string

THe string value that is about to be set.

Returns

bool

A value indicating whether the string value is valid.

Implements IMaskProvider.Validate(string)

WireEvents()

Attaches to events.

Declaration

cs-api-definition
public void WireEvents()