HeaderPane
Main
Hide
Share Link
Print

InputMode Property, SftMask Object

Defines insert/overtype mode behavior.

Syntax

Get

C#SftMaskInputModeConstants Mode = object.InputMode;
VB.NETMode = object.InputMode As SftMaskInputModeConstants
C++enum SftMaskInputModeConstants Mode = object->InputMode;
enum SftMaskInputModeConstants Mode = object->GetInputMode();
CHRESULT object->get_InputMode(enum SftMaskInputModeConstants* Mode);

Put

C#SftMaskInputModeConstants object.InputMode = Mode;
VB.NETobject.InputMode = Mode As SftMaskInputModeConstants
C++enum SftMaskInputModeConstants object->InputMode = Mode;
void object->PutInputMode(enum SftMaskInputModeConstants Mode);
CHRESULT object->put_InputMode(enum SftMaskInputModeConstants Mode);

object

A SftMask object.

Mode

Defines insert/overtype mode behavior.

ModeValueDescription
inputSftMaskInsertOnly0The control is in insert mode. The user cannot switch to overtype mode. The application can switch to overtype mode using the Insert property.
inputSftMaskInsert1The control is in insert mode. The user and the application can switch back and forth between insert and overtype mode. Each control maintains its own insert/overtype state, which is active until the control is destroyed.
inputSftMaskOvertype2The control is in overtype mode. The user and the application can switch back and forth between insert and overtype mode. Each control maintains its own insert/overtype state, which is active until the control is destroyed.
inputSftMaskInsertEntry3The control is in insert mode. The user and the application can switch back and forth between insert and overtype mode. The control returns to insert mode whenever it receives the input focus.
inputSftMaskOvertypeEntry4The control is in overtype mode. The user and the application can switch back and forth between insert and overtype mode. The control returns to overtype mode whenever it receives the input focus.
inputSftMaskInsertAppGlobal5All Masked Edit controls within the application are in insert mode. The user and the application can switch back and forth between insert and overtype mode globally for all Masked Edit controls. All controls share the same insert/overtype state, which is active until the application ends.

Comments

The InputMode property defines insert/overtype mode behavior.

Overtype mode is visually indicated by the selection which is automatically extended to include one character position (if possible).

The user switches between insert and overtype mode using the Insert key. The application can switch between modes using the Insert property.

To allow an application to display the current insert/overtype mode, e.g., in a status bar, the InputModeUpdate event is used to notify the application of any mode change that may occur, through user interaction, input focus change or application driven changes. By responding to the InputModeUpdate event, an application is guaranteed to be notified of the current input mode.

Examples

C# View entire sample code

private void Form1_Load(object sender, System.EventArgs e)
{
    axSftMask1.Caption.Text = "Insert->";
    axSftMask1.InputMode = SftMaskInputModeConstants.inputSftMaskInsert;
    axSftMask2.Caption.Text = "Overtype->";
    axSftMask2.InputMode = SftMaskInputModeConstants.inputSftMaskOvertype;
}

private void axSftMask1_InputModeUpdate(object sender, AxSftMaskLib80._ISftMaskEvents_InputModeUpdateEvent e)
{
    label1.Text = e.insertMode.ToString();
}

private void axSftMask2_InputModeUpdate(object sender, AxSftMaskLib80._ISftMaskEvents_InputModeUpdateEvent e)
{
    label1.Text = e.insertMode.ToString();

VB.NET View entire sample code

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    AxSftMask1.Caption.Text = "Insert->"
    AxSftMask1.InputMode = SftMaskInputModeConstants.inputSftMaskInsert
    AxSftMask2.Caption.Text = "Overtype->"
    AxSftMask2.InputMode = SftMaskInputModeConstants.inputSftMaskOvertype
End Sub

Private Sub AxSftMask1_InputModeUpdate(ByVal sender As Object, ByVal e As AxSftMaskLib80._ISftMaskEvents_InputModeUpdateEvent) Handles AxSftMask1.InputModeUpdate
    Label1.Text = e.insertMode
End Sub

Private Sub AxSftMask2_InputModeUpdate(ByVal sender As Object, ByVal e As AxSftMaskLib80._ISftMaskEvents_InputModeUpdateEvent) Handles AxSftMask2.InputModeUpdate
    Label1.Text = e.insertMode
End Sub

C++ View entire sample code

    CDialog::OnInitDialog();

    m_pMask1 = m_Mask1.GetControlUnknown();
    _ASSERT(m_pMask1 != NULL);
    m_pMask2 = m_Mask2.GetControlUnknown();
    _ASSERT(m_pMask2 != NULL);

    m_pMask1->Caption->Text = _T("Insert->");
    m_pMask1->InputMode = inputSftMaskInsert;
    m_pMask2->Caption->Text = _T("Overtype->");
    m_pMask2->InputMode = inputSftMaskOvertype;

    return TRUE;
}

void CProject1Dlg::OnInputModeUpdateSftMask1(BOOL InsertMode)

See Also SftMask Object | Object Hierarchy


Last Updated 11/15/2026 - (email)
© 2026 Softel vdm, Inc.