MaskedTextBox
MaskedTextBox
Namespace: Wisej.Web
Assembly: Wisej.Framework (3.0.0.0)
Uses a mask to distinguish between proper and improper user input.
- C#
- VB.NET
public class MaskedTextBox : TextBoxBase
Public Class MaskedTextBox
Inherits TextBoxBase
The MaskedTextBox class is an enhanced TextBox control that supports a declarative syntax for accepting or rejecting user input. Using the Mask property, you can enforce the following input types without writing any custom validation logic in your application:
- Required input characters.
- Optional input characters.
- The type of input expected at a given position in the mask; for example, a digit, or an alphabetic or alphanumeric character.
- Mask literals, or characters that should appear directly in the MaskedTextBox; for example, the hyphens(-) in a phone number, or the currency symbol in a price.
- Special processing for input characters; for example, to convert alphabetic characters to uppercase.
- Special processing for input characters; for example, to convert alphabetic characters to uppercase.
When a MaskedTextBox control is displayed at run time, it represents the mask as a series of prompt characters and optional literal characters. Each editable mask position, representing a required or optional input, is shown with a single prompt character. For example, the number sign (#) is often used as a placeholder for a numeric character input. You can use the PromptChar property to specify a custom prompt character. The HidePromptOnLeave property determines if the user sees the prompt characters when the control loses input focus
Constructors
MaskedTextBox()
Initializes a new instance of the MaskedTextBox class using defaults.
MaskedTextBox(mask)
Initializes a new instance of the MaskedTextBox class using the specified input mask.
Throws:
- ArgumentNullException mask is null.
Properties
CharacterCasing
CharacterCasing: Returns or sets whether the MaskedTextBox control modifies the case of characters as they are typed.
Culture
CultureInfo: Returns or sets the culture information associated with the masked text box.
HidePromptOnLeave
Boolean: Returns or sets whether the prompt characters in the input mask are hidden when the masked text box loses focus.
InputType
InputType: Specifies the type, min, max and step properties to associate to the element.
Mask
String: Returns or sets the input mask.
The Mask is a string that defines the masking characters and the literals to display and process during user input and when reading the Text property. Server side masking is processed by an instance of the MaskedTextProvider class exposed by the MaskedTextProvider property. On the client side, the mask processing is performed by the "wisej.utils.MaskProvider.js" class while the user edits the input field.
Masking Character Description 0 Digit, required. This element will accept any single digit between 0 and 9. 9 Digit or space, optional.
Digit or space, optional. If this position is blank in the mask, it will be rendered as a space in the Text property. Plus (+) and minus (-) signs are allowed. L Letter, required. Restricts input to the ASCII letters a-z and A-Z. This mask element is equivalent to [a-zA-Z] in regular expressions. ? Letter, optional. Restricts input to the ASCII letters a-z and A-Z. This mask element is equivalent to [a-zA-Z]? in regular expressions. & Character, required. This element behaves like the "L" element. C Character, optional. Any non-control character. This element behaves like the "?" element. A Alphanumeric, required. The only characters it will accept are the ASCII letters a-z and A-Z. This mask element behaves like the "a" element. a Alphanumeric, optional. The only characters it will accept are the ASCII letters a-z and A-Z. This mask element behaves like the "A" element. . Decimal placeholder. The actual display character used will be the decimal symbol appropriate to the format provider, as determined by the control's FormatProvider property. , Thousands placeholder. The actual display character used will be the thousands placeholder appropriate to the format provider, as determined by the control's FormatProvider property. : Time separator. The actual display character used will be the time symbol appropriate to the format provider, as determined by the control's FormatProvider property. / Date separator. The actual display character used will be the date symbol appropriate to the format provider, as determined by the control's FormatProvider property. $ Currency symbol. The actual character displayed will be the currency symbol appropriate to the format provider, as determined by the control's FormatProvider property. < Shift down. Converts all characters that follow to lowercase.
Shift up. Converts all characters that follow to uppercase. | Disable a previous shift up or shift down.
Escape. Escapes a mask character, turning it into a literal. "\" is the escape sequence for a backslash. Others Literals. All non-mask elements will appear as themselves within MaskedTextBox. Literals always occupy a static position in the mask at run time, and cannot be moved or deleted by the user. If you change the Mask when the control already contains a value, it will apply the new mask to the existing text. The decimal (.), thousand (,), time (:), date (/), and currency ($) symbols default to displaying those symbols as defined by the application's culture. You can force a specific MaskedTextBox to display symbols for another culture by using the Culture property. Otherwise you can set the application-wide culture by setting the CurrentCulture property.
MaskedTextProvider
MaskedTextProvider: Returns the mask provider associated with this instance of the masked text box control.
PasswordChar
Char: Returns or sets the character used to mask characters of a password in a single-line MaskedTextBox control.
This property only enables/disables the password mode for the textbox. It doesn't change the password masking character used by the browser.
PromptChar
Char: Returns or sets the character used to represent the absence of user input in the MaskedTextBox control.
Throws:
- ArgumentException The character specified when setting this property is not a valid prompt character.
RejectInputOnFirstFailure
Boolean: Returns or sets whether the parsing of input text should stop after the first invalid character is reached.
SpellCheck
Boolean: Returns or sets whether the text in the MaskedTextBox is spell checked by the browser.
Text
String: Returns or sets the current text in the text box.
TextAlign
HorizontalAlignment: Returns or sets how text is aligned in a TextBox control.
TextLength
Int32: Returns the length of text in the control.
TextMaskFormat
MaskFormat: Returns or sets a value that determines whether literals and prompt characters are included in the formatted string.
ValidatingType
Type: Returns or sets the data type used to verify the data input by the user.
Methods
ValidateText()
Converts the user input string to an instance of the validating type.
Returns: Object. If successful, an Object of the type specified by the ValidatingType property; otherwise, null to indicate conversion failure.
Throws:
- Exception A critical exception occurred during the parsing of the input string.
Events
CultureChanged
EventHandler Fired when the value of the Culture property has changed.
MaskChanged
EventHandler Fired when the value of the Mask property has changed.
TextAlignChanged
EventHandler Fired when the value of the TextAlign property has changed.
TypeValidationCompleted
TypeValidationEventHandler Occurs when MaskedTextBox has finished parsing the current value using the ValidatingType property.
Inherited
Properties
| Name | Description | From |
|---|---|---|
| AccessibleDescription | Returns or sets the description that will be reported to accessibility client applications. It is assigned to the "alt" attribute of the browser element. | Control |
| AccessibleName | Returns or sets the name of the control for use by accessibility client applications. It is assigned to the "name" attribute of the browser element. | Control |
| AccessibleRole | Returns or sets the accessible role of the control that will be reported to accessibility client applications. It is assigned to the "role" attribute of the browser element. | Control |
| AllowDrag | Returns or sets whether the control can initiate a drag-drop operation. | Control |
| AllowDrop | Returns or sets whether the control can accept data that the user drags onto it. | Control |
| Anchor | Returns or sets the edges of the container to which a control is bound and determines how a control is resized with its parent. | Control |
| Anonymous | Returns or sets whether the control receives pointer events. Anonymous controls let pointer events bubble to their parents. | Control |
| AppearanceKey | Sets the appearance key for the theme engine. | Control |
| AutoSize | Returns or sets whether the height of the control is set automatically. | TextBoxBase |
| BackColor | Returns or sets the background color for the control. | Control |
| BackgroundImage | Returns or sets the background image displayed in the control. | Control |
| BackgroundImageLayout | Returns or sets the background image layout as defined in the ImageLayout enumeration. | Control |
| BackgroundImageSource | Returns or sets the background image displayed in the control. | Control |
| BecomingActiveControl | Returns a flag indicating that the control is becoming the active control. | Control |
| BindingContext | Returns or sets the BindingContext for the control. | Control |
| BorderStyle | Returns or sets the border type of the text box control. | TextBoxBase |
| Bottom | Returns the distance, in pixels, between the bottom edge of the control and the top edge of its container's client area. | Control |
| Bounds | Returns or sets the size and location of the control including its non-client area, in pixels and relative to the parent control. | Control |
| CanExecute | Determines whether the control can execute a command. | Control |
| CanFocus | Returns whether the control can receive focus. | Control |
| CanSelect | Returns whether the control can be selected. | Control |
| CanUndo | Returns a value indicating whether the user can undo the previous operation in a text box control. | TextBoxBase |
| Capture | Returns or sets whether the control has captured the mouse. | Control |
| CausesValidation | Returns or sets whether the control causes validation to be performed on controls that require to be validated when this control receives focus. | Control |
| ClientEvents | Returns a collection of client events and JavaScript listeners. You may attach multiple listeners to same event. | Control |
| ClientRectangle | Returns the client rectangle of the control. | Control |
| ClientSize | Returns or sets the height and width of the client area. | Control |
| ContainsFocus | Indicates whether the control, or one of its child controls, has the input focus. | Control |
| ContextMenu | Returns or sets the shortcut menu associated with the control. | Control |
| Controls | Returns the collection of controls contained within the control. | Control |
| Created | Returns a value indicating whether the control has been created. | Control |
| CssClass | Returns or sets additional CSS class names to add to the widget. | Control |
| CssStyle | Returns or sets the custom CSS styles to add to the widget. | Control |
| Cursor | Returns or sets the cursor that is displayed when the mouse pointer is over the control. | Control |
| DataBindings | Returns the data bindings for the control. | Control |
| DisplayRectangle | Returns the rectangle that represents the virtual display area of the control. | Control |
| Disposing | Returns whether the control is in the process of disposing itself and child controls. | Control |
| Dock | Returns or sets which control borders are docked to its parent control and determines how a control is resized with its parent. | Control |
| Enabled | Returns or sets whether the control can respond to user interaction. | Control |
| EnableNativeContextMenu | Enables or disables the browser's context menu. | TextBoxBase |
| Focusable | Returns or sets whether the control can gain the focus. | Control |
| Focused | Returns a value indicating whether the control has input focus. | Control |
| Font | Gets or sets the font of the text displayed by the control. | Control |
| ForeColor | Returns or sets the text color of the control. | Control |
| Handle | Returns the unique server-side id (handle) for this component. | Control |
| HasChildren | Returns whether the control contains any child control. | Control |
| HasDataBindings | Returns whether the control specifies data bindings. | Control |
| HasResponsiveProfiles | Check if the control defines any responsive profile without forcing the creation of the collection. | Control |
| HasUserData | Checks if the UserData dynamic object was created and has any value. | Control |
| Height | Returns or sets the height of the control. | Control |
| InitScript | Returns or sets an initialization script to execute when the widget is created (or reloaded) in the browser. | Control |
| Invalid | Returns or sets a value that indicates that the control is invalid. | TextBoxBase |
| InvalidMessage | Returns or sets the invalid message that is shown in the invalid tooltip. | TextBoxBase |
| IsDisposed | Returns whether the control has been disposed. | Control |
| IsHandleCreated | Returns if the control has a server-side component id (handle) associated with it. | Control |
| IsMirrored | Returns whether the control is mirrored. | Control |
| Label | Provides a label related to the control. | TextBoxBase |
| LabelText | Returns or sets the localizable label associated with this control. | TextBoxBase |
| LayoutEngine | Returns the control's layout engine. | Control |
| Left | Returns or sets the distance, in pixels, between the left edge of the control and the left edge of its container's client area. | Control |
| Location | Returns or sets the coordinates of the upper-left corner of the control relative to the upper-left corner of its container. | Control |
| Margin | Returns or sets the space between controls. | Control |
| MaximumSize | Returns or sets the maximum size for the control. | Control |
| MaxLength | Returns or sets the maximum number of characters the user can type or paste into the text box control. | TextBoxBase |
| MinimumSize | Returns or sets the minimum size for the control. | Control |
| Modified | Returns or sets a value that indicates that the text box control has been modified by the user since the control was created or its contents were last set. | TextBoxBase |
| Movable | Returns or sets whether the control can be moved by dragging. | Control |
| Name | Gets or sets the name of the control. | Control |
| Padding | Returns or sets padding within the control. | Control |
| Parent | Returns or sets the parent container of the control. | Control |
| PreferredSize | Returns the preferred size in which the control can fit. | Control |
| ReadOnly | Returns or sets whether the text box control is read-only. | TextBoxBase |
| ResizableEdges | Returns or sets the edges of the control that can be dragged to resize the control. | Control |
| ResponsiveProfiles | Returns the collection of responsive properties that have been set for this control. | Control |
| Right | Return the distance, in pixels, between the right edge of the control and the left edge of its container's client area. | Control |
| RightToLeft | Returns or sets whether the control's elements are aligned right-to-left to support RTL languages. | Control |
| SelectedText | Returns or sets a value indicating the currently selected text in the control. | TextBoxBase |
| SelectionLength | Returns or sets the number of characters selected in the text box. | TextBoxBase |
| SelectionStart | Returns or sets the starting point of text selected in the text box. | TextBoxBase |
| SelectOnEnter | Selects the text when gaining the focus. | TextBoxBase |
| ShowLoader | Returns or sets whether the control is blocked by the ajax loader. | Control |
| Size | Returns or sets the height and width of the control. | Control |
| States | Returns or sets additional theme states to the client widget. | Control |
| TabIndex | Returns or sets the tab order of the control within its container. | Control |
| TabStop | Returns or sets whether the user can give the focus to this control using the TAB key and the Focusable property is set to true. | Control |
| Tag | Returns or sets the object that contains data about the control. | Control |
| Tools | Returns the instance of ComponentToolCollection associated with this control. | TextBoxBase |
| ToolTipText | Returns or sets the tooltip text to show for this control. | Control |
| Top | Returns or sets the distance, in pixels, between the top edge of the control and the top edge of its container's client area. | Control |
| TopLevelControl | Returns the parent control that is not parented by another Form. Typically, this is the outermost Form that the control is contained in. | Control |
| UserData | Returns a dynamic object that can be used to store custom data in relation to this control. | Control |
| UseWaitCursor | Returns or sets whether to use the wait cursor for the current control and all child controls. | Control |
| ValidationCancelled | Returns a flag indicating that the validation has been canceled. | Control |
| Visible | Returns or sets whether the control and all its child controls are displayed. | Control |
| Watermark | Returns or sets the text to show when the textbox is empty. | TextBoxBase |
| Width | Returns or sets the width of the control. | Control |
Methods
| Name | Description | From |
|---|---|---|
| AddClientEventListener(name, script) | Adds a new listener script to the event name to the client widget. | Control |
| AddCssClass(name) | Adds the CSS class name to the widget element. If the class already exists in the CssClass it's not added. | Control |
| AddState(state) | Adds the specified theme state to the widget. | Control |
| AppendText(text) | Appends text to the current text of a text box. | TextBoxBase |
| BeginInvoke(method) | Executes the specified delegate asynchronously. | Control |
| BeginInvoke(method, args) | Executes the specified delegate asynchronously. | Control |
| BringToFront() | Brings the control to the front of the z-order. | Control |
| Call(function, args) | Runs the JavaScript function within the component's context in the browser. | Control |
| Call(function, callback, args) | Runs the JavaScript function within the component's context in the browser and returns the value to the callback method. | Control |
| CallAsync(function, args) | Asynchronously runs the JavaScript function within the component's context in the browser and returns an awaitable Task containing the value returned by the remote call. | Control |
| CenterToParent() | Centers the position of the control within the bounds of the parent. | Control |
| CenterToParent(horizontal, vertical) | Centers the position of the control within the bounds of the parent either horizontally, vertically or both. | Control |
| Clear() | Clears all text from the text box control. | TextBoxBase |
| Contains(control) | Indicates whether the specified control is a child of this control. | Control |
| Copy() | Copies the current selection in the text box to the Clipboard. | TextBoxBase |
| CreateControl() | Creates and register this control and all its children. | Control |
| Cut() | Moves the current selection in the text box to the Clipboard. | TextBoxBase |
| DeselectAll() | Specifies that the value of the SelectionLength property is zero so that no characters are selected in the control. | TextBoxBase |
| DoDragDrop(data, allowedEffects) | Begins a drag-and-drop operation. | Control |
| DoDragDrop(data, allowedEffects, imageSource) | Begins a drag-and-drop operation. | Control |
| DoDragDrop(data, allowedEffects, imageSource, imageSize) | Begins a drag-and-drop operation. | Control |
| DoDragDrop(data, allowedEffects, image) | Begins a drag-and-drop operation. | Control |
| DoDragDrop(data, allowedEffects, image, imageSize) | Begins a drag-and-drop operation. | Control |
| EndInvoke(asyncResult) | Retrieves the return value from the asynchronous operation represented by asyncResult . | Control |
| Eval(javaScript) | Runs the javaScript code within the component's context in the browser. | Control |
| Eval(javaScript, callback) | Runs the javaScript code within the component's context in the browser and returns the value to the callback method. | Control |
| EvalAsync(javaScript) | Asynchronously runs the javaScript code within the component's context in the browser and returns an awaitable Task that contains the value returned by the remote call. | Control |
| FindForm() | Retrieves the form that the control is on. | Control |
| FindPage() | Retrieves the page that the control is on. | Control |
| Focus() | Sets input focus to the control. | Control |
| GetChildAtPoint(pt, skipValue) | Retrieves the child control that is located at the specified coordinates, specifying whether to ignore child controls of a certain type. | Control |
| GetChildAtPoint(pt) | Retrieves the child control that is located at the specified coordinates. | Control |
| GetClientEventListener(id) | Returns the script associated to the listener identified by id . | Control |
| GetClientEventListener(name) | Returns the scripts for all the listeners attached to the event name . | Control |
| GetContainerControl() | Returns the next IContainerControl up the control's chain of parents. | Control |
| GetNextControl(control, forward) | Retrieves the next control forward or back in the tab order of child controls. | Control |
| GetStyle(flag) | Retrieves the value of the specified control style bit for the control. | Control |
| HasClientEventListener(name) | Checks whether the specified event name has any listener attached. | Control |
| HasCssClass(name) | Returns true if the property CssClass contains the specified class name . | Control |
| HasState(state) | Checks whether the specified theme state is present in the States property. | Control |
| Hide() | Conceals the control from the user. | Control |
| Invalidate() | Causes the control to update the client side widget. When in design mode, causes the rendered control to update its entire surface in the designer. | Control |
| Invalidate(invalidateChildren) | Causes the control to update the client side widget. When in design mode, causes the rendered control to update its entire surface in the designer. | Control |
| Invoke(method) | Executes the specified delegate. | Control |
| Invoke(method, args) | Executes the specified delegate, on the thread that owns the control's underlying window handle, with the specified list of arguments. | Control |
| LayoutChildren(dock, spacing, useMargins, hAlign, vAlign) | Arranges all the child Control using the specified dock style, spaced by spacing pixels. | Control |
| LayoutChildren(dock, viewArea, spacing, useMargins, hAlign, vAlign) | Arranges all the child Control using the specified dock style, spaced by spacing pixels. | Control |
| LayoutChildren(controls, dock, spacing, useMargins, hAlign, vAlign) | Arranges all the child Control using the specified dock style, spaced by spacing pixels. | Control |
| LayoutChildren(controls, dock, viewArea, spacing, useMargins, hAlign, vAlign) | Arranges all the child Control using the specified dock style, spaced by spacing pixels. | Control |
| LayoutChildren(direction, spacing, useMargins, hAlign, vAlign) | Arranges all the child Control in the specified direction , spaced by spacing pixels. | Control |
| LayoutChildren(direction, viewArea, spacing, useMargins, hAlign, vAlign) | Arranges all the child Control in the specified direction , spaced by spacing pixels, and constrained within the specified viewArea . | Control |
| LayoutChildren(controls, direction, spacing, useMargins, hAlign, vAlign) | Arranges the specified child controls in the specified direction , spaced by spacing pixels. | Control |
| LayoutChildren(controls, direction, viewArea, spacing, useMargins, hAlign, vAlign) | Arranges the specified child controls in the specified direction , spaced by spacing pixels, and constrained within the specified viewArea . | Control |
| Paste() | Replaces the current selection in the text box with the contents of the Clipboard. | TextBoxBase |
| PerformLayout() | Forces the control to apply layout logic to all its child controls. | Control |
| PerformLayout(affectedControl, affectedProperty) | Forces the control to apply layout logic to all its child controls. | Control |
| PointToClient(point) | Computes the location of the specified screen point into client coordinates. | Control |
| PointToScreen(point) | Computes the location of the specified client point into screen coordinates. | Control |
| RectangleToClient(rect) | Computes the size and location of the specified screen rectangle in client coordinates. | Control |
| RectangleToScreen(rect) | Computes the size and location of the specified client rectangle in screen coordinates. | Control |
| Refresh() | Forces the control to update corresponding client widget. When in DesignMode it forces a full redraw of the designer surface for this control, including the non-client areas such as the caption of forms or panels. | Control |
| Refresh(refreshChildren) | Forces the control to update corresponding client widget. When in DesignMode it forces a full redraw of the designer surface for this control and optionally of its children, including the non-client areas such as the caption of forms or panels. | Control |
| RemoveClientEventListener(id) | Detaches and removes the listener identified by id . | Control |
| RemoveClientEventListener(name) | Removes all the listeners attached to the event name . | Control |
| RemoveCssClass(name) | Removes the specified css class name from the control's CssClass property. | Control |
| RemoveState(state) | Removes the specified theme state from the widget. | Control |
| ResetBindings() | Removes all the data bindings from the control. | Control |
| ResumeLayout() | Resumes layout logic. | Control |
| ResumeLayout(performLayout) | Resumes layout logic, optionally forcing an immediate layout of all pending layout requests. | Control |
| ScrollControlIntoView(alignX, alignY) | Scrolls the control into view in the container using the specified alignX and alignY preferences. | Control |
| ScrollControlIntoView() | Scrolls the child control into view. | Control |
| ScrollToX(x) | Scrolls to the given left position. | TextBoxBase |
| ScrollToY(y) | Scrolls to the given top position. | TextBoxBase |
| Select(start, length) | Selects a range of text in the text box. | TextBoxBase |
| Select() | Activates a control. | Control |
| SelectAll() | Selects all text in the text box. | TextBoxBase |
| SelectNextControl(control, forward, tabStopOnly, nested, wrap) | Activates the next control in the list according to the specified selection rules. | Control |
| SendToBack() | Sends the control to the back of the z-order. | Control |
| SetBounds(x, y, width, height) | Sets the bounds of the control to the specified location and size. | Control |
| SetBounds(x, y, width, height, specified) | Sets the specified bounds of the control to the specified location and size. | Control |
| Show() | Displays the control to the user. | Control |
| SuspendLayout() | Suspends the layout logic for the control. | Control |
| Update() | Causes the control to update the corresponding client side widget. When in design mode, causes the rendered control to update its entire surface in the designer. | Control |
| ValidateChildren(flags) | Validates all the child controls in the container. Exactly which controls are validated and which controls are skipped is determined by flags . | Control |
| ValidateChildren() | Validates all selectable child controls in the container, including descendants. This is equivalent to calling ValidateChildren(ValidationConstraints.Selectable). See Selectable for details of exactly which child controls will be validated. | Control |
Events
| Name | Description | From |
|---|---|---|
| Appear | Fired after the control has been fully rendered on the client. | Control |
| AutoSizeChanged | Fired when the AutoSize property value changes. | Control |
| BackColorChanged | Fired when the value of the BackColor property changes. | Control |
| BackgroundImageChanged | Fired when the value of the BackgroundImage property changes. | Control |
| BackgroundImageLayoutChanged | Fired when the BackgroundImageLayout property changes. | Control |
| BecomingActiveControlChanged | Fired when the value of the BecomingActiveControl property changes. | Control |
| BindingContextChanged | Occurs when the value of the BindingContext property changes. | Control |
| CausesValidationChanged | Fired when the value of the CausesValidation property changes. | Control |
| Click | Fired when the control is clicked. | Control |
| ClientSizeChanged | Fired when the ClientSize property value changes. | Control |
| ContextMenuChanged | Fired when the value of the ContextMenu property changes. | Control |
| ControlAdded | Fired when a new control is added to the ControlCollection. | Control |
| ControlCreated | Fired when a control is made visible the first time, fully created and sent to the client. | Control |
| ControlRemoved | Fired when a control is removed from the ControlCollection. | Control |
| CursorChanged | Fired when the value of the Cursor property changes. | Control |
| Disappear | Fired after the control is no longer visible on the client. | Control |
| Disposed | Fired when the component is disposed. | Control |
| DockChanged | Fired when the value of the Dock property changes. | Control |
| DoubleClick | Fired when the control is double-clicked. | Control |
| DragDrop | Fired when a drag-and-drop operation is completed. | Control |
| DragEnd | Fired when a drag-drop operation is terminated either by a drop or canceled. | Control |
| DragEnter | Fired when an object is dragged into the control's bounds. | Control |
| DragLeave | Fired when an object is dragged out of the control's bounds. | Control |
| DragOver | Fired when an object is dragged over the control's bounds. | Control |
| DragStart | Fired when a drag-drop operation is started by the user. | Control |
| EnabledChanged | Fired when the Enabled property value has changed. | Control |
| EndMove | Fired when a control is Movable and the user ends the move operation. | Control |
| EndResize | Fired when a control has ResizableEdges and the user ends the resize operation. | Control |
| Enter | Fired when the control gains the input focus. | Control |
| FontChanged | Fired when the Font property value changes. | Control |
| ForeColorChanged | Fired when the ForeColor property value changes. | Control |
| GotFocus | Fired when the control gains the focus. | Control |
| HelpRequested | Fired when the user requests help for a control by pressing F1. | Control |
| ImeModeChanged | Fired when the ImeMode property has changed. | Control |
| KeyDown | Fired when a key is pressed while the control has focus. | Control |
| KeyPress | Fired when a key is pressed while the control has focus. | Control |
| KeyUp | Fired when a key is released while the control has focus. | Control |
| Layout | Fired when a control should reposition its child controls. | Control |
| Leave | Fired when the control loses the input focus. | Control |
| LocationChanged | Fired when the Location property value has changed. | Control |
| LongTap | Fired when a pointer holds on the screen. | Control |
| LostFocus | Fired when the control loses focus. | Control |
| MarginChanged | Fired when the control's margin changes. | Control |
| ModifiedChanged | Fired when the value of the Modified property has changed. | TextBoxBase |
| MouseCaptureChanged | Fired when the control loses mouse capture. | Control |
| MouseClick | Fired when the control is clicked by the mouse. | Control |
| MouseDoubleClick | Fired when the control is double clicked by the mouse. | Control |
| MouseDown | Fired when the mouse pointer is over the control and a mouse button is pressed. | Control |
| MouseEnter | Fired when the mouse pointer enters the control. | Control |
| MouseHover | Fired when the mouse pointer rests on the control. | Control |
| MouseLeave | Fired when the mouse pointer leaves the control. | Control |
| MouseMove | Fired when the mouse pointer is moved over the control. | Control |
| MouseUp | Fired when the mouse pointer is over the control and a mouse button is released. | Control |
| MouseWheel | Fired when the mouse wheel moves while the control has focus. | Control |
| PaddingChanged | Fired when the control's padding changes. | Control |
| Paint | Fired when a UserPaint control needs to redraw itself. | Control |
| ParentChanged | Fired when the Parent property value changes. | Control |
| Pinch | Fired when two finger moved towards or away from each other. It contains the scaling factor of the pinch. | Control |
| PreviewKeyDown | Fired before the KeyDown event when a key is pressed while focus is on this control. | Control |
| QueryContinueDrag | Occurs during a drag-and-drop operation and enables the drag source to determine whether the drag-and-drop operation should be canceled. | Control |
| ReadOnlyChanged | Fired when the value of the ReadOnly property has changed. | TextBoxBase |
| Resize | Fired when the control is resized. | Control |
| ResponsiveProfileChanged | Fired when the active responsive profile is changed. | Control |
| RightToLeftChanged | Fired when the RightToLeft property value changes. | Control |
| Rotate | Fired when two finger moved around a single point. It contains the angle of the rotation. | Control |
| SizeChanged | Fired when the Size property value changes. | Control |
| StartMove | Fired when a control is Movable and the user begins the move operation. | Control |
| StartResize | Fired when a control has ResizableEdges and the user begins the resize operation. | Control |
| StyleChanged | Fired when the control style changed. | Control |
| Swipe | Fired when a pointer swipes over the screen. | Control |
| TabIndexChanged | Fired when the TabIndex property value has changed. | Control |
| TabStopChanged | Fired when the value of the TabStop property changes. | Control |
| Tap | Fired when a pointer taps on the screen. | Control |
| TextChanged | Fired when the Text property value changes. | Control |
| ToolClick | Fired when a ComponentTool is clicked. | TextBoxBase |
| TouchCancel | Fired when a touch point has been disrupted in an implementation-specific manner (for example, too many touch points are created). | Control |
| TouchEnd | Fired when a touch point is removed from the touch surface. | Control |
| TouchMove | Fired when a touch point is moved along the touch surface. | Control |
| TouchStart | Fired when a touch point is placed on the touch surface. | Control |
| Track | Fired when a pointer grabs an item and moves the pointer on it. | Control |
| Validated | Fired when the control is finished validating. | Control |
| Validating | Fired when the control is validating. | Control |
| VisibleChanged | Fired when the Visible property value changes. | Control |
| WidgetEvent | Fired when the control receives a custom event from the client. | Control |
Extension Methods
| Name | Description | From |
|---|---|---|
| Beep(Target, AudioBase64) | Sounds a tone through the computer's speaker. | Interaction |
| InputBox(Target, Prompt, Title, DefaultResponse, XPos, YPos, CloseCallback) | Displays a prompt in a dialog box, waits for the user to input text or click a button, and then returns a string containing the contents of the text box. | Interaction |
| InputBoxAsync(Target, Prompt, Title, DefaultResponse, XPos, YPos) | Asynchronous displays a prompt in a dialog box, waits for the user to input text or click a button, and then returns a string containing the contents of the text box. | Interaction |
| MsgBox(Target, Prompt, Buttons, Title, CloseCallback) | Displays a message in a dialog box, waits for the user to click a button, and then returns an integer indicating which button the user clicked. | Interaction |
| MsgBoxAsync(Target, Prompt, Buttons, Title) | Asynchronously displays a message in a dialog box, waits for the user to click a button, and then returns an integer indicating which button the user clicked. | Interaction |
| ToJSON(obj, formatted) | Serializes the object to a JSON string. | JSON |
| ToJSON(obj, options) | Serializes the object to a JSON string. | JSON |
Inherited By
| Name | Description |
|---|---|
| DataGridViewMaskedTextBoxEditingControl | Represents a MaskedTextBox control that can be hosted in a DataGridViewMaskedTextBoxCell cell. |
Implements
| Name | Description |
|---|---|
| IBindableComponent | Bindable components implement this interface. |
| ILabel | Provides access to the LabelWrapper associated with the controls that implement this interface. |
| IReadOnly | Provides access to the ReadOnly property for coontrols that support the read-only mode. |
| IModified | Provides access to the Modified property and ModifiedChanged event for controls that implement this interface. |
| IWisejComponent | All wisej components implement this interface. |
| IWisejControl | All wisej controls derived from the Control class must implement this interface. |
| IWisejSerializable | Allows an object to serialize itself. |