SftButton/DLL 3.0 - Button Control
SftTree/DLL 8.0 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 4.0 - Button Control
SftMask/OCX 7.0 - Masked Edit Control
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 8.0 - Tree Control
SftButton/DLL 3.0 - Button Control
SftTree/DLL 8.0 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 4.0 - Button Control
SftMask/OCX 7.0 - Masked Edit Control
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 8.0 - Tree Control
SftTree/NET 2.0 - Tree Control
In addition to the standard Windows messages (WM_SETFONT, WM_COMMAND, WM_NOTIFY, etc.) that a SftMask control understands as a first-class Windows window, the control defines the following custom messages. Most applications use the SftMask_* helper functions instead of sending these messages directly, but the messages are documented here for applications that need to bypass the helper layer.
Note: use the SetText / GetText functions (SFTMASKM_SETTEXT / SFTMASKM_GETTEXT) instead of WM_SETTEXT / WM_GETTEXT, which operate on the display text.
| Message | Value | Description |
|---|---|---|
| SFTMASKM_CANUNDO | WM_USER+1 | Return whether an undo operation is possible (CanUndo). |
| SFTMASKM_EMPTYUNDO | WM_USER+2 | Empty the undo buffer (EmptyUndo). |
| SFTMASKM_GETCHARINDEX | WM_USER+3 | Return the character index at a position (GetCharIndex). |
| SFTMASKM_GETCHARPOS | WM_USER+4 | Return the bounding rectangle of a character range (GetCharPos). |
| SFTMASKM_GETCONTROLINFO | WM_USER+5 | Retrieve the SFTMASK_CONTROL structure (GetControlInfo). |
| SFTMASKM_GETDESIGN | WM_USER+6 | Return the design-mode flag (GetDesign). |
| SFTMASKM_GETPOSITION | WM_USER+7 | Return the bounding rectangle of a control area (GetPosition). |
| SFTMASKM_GETSELTEXT_A | WM_USER+8 | Retrieve the selected text (ANSI). |
| SFTMASKM_GETSELTEXT_W | WM_USER+9 | Retrieve the selected text (Unicode). |
| SFTMASKM_GETTEXTDISPLAY_A | WM_USER+10 | Retrieve the display text (ANSI). |
| SFTMASKM_GETTEXTDISPLAY_W | WM_USER+11 | Retrieve the display text (Unicode). |
| SFTMASKM_HITTEST | WM_USER+12 | Determine the control area at a position (HitTest). |
| SFTMASKM_ISEMPTY | WM_USER+13 | Return whether the control is empty (IsEmpty). |
| SFTMASKM_ISVALID | WM_USER+14 | Return whether the contents are valid (IsValid). |
| SFTMASKM_ISVALID_WITHMSG | WM_USER+15 | Validate the contents, displaying an error message if invalid (IsValidWithMsg). |
| SFTMASKM_NEXTCONTROL | WM_USER+16 | Move the input focus to the next control (NextControl). |
| SFTMASKM_OPTIMALPOSITION | WM_USER+17 | Position the caret at the optimal input position (OptimalPosition). |
| SFTMASKM_PREVCONTROL | WM_USER+18 | Move the input focus to the previous control (PrevControl). |
| SFTMASKM_QUERYCHAR_A | WM_USER+19 | Test whether the control accepts a character (ANSI). |
| SFTMASKM_QUERYCHAR_W | WM_USER+20 | Test whether the control accepts a character (Unicode). |
| SFTMASKM_SETCONTROLINFO | WM_USER+21 | Apply a SFTMASK_CONTROL structure (SetControlInfo). |
| SFTMASKM_SETDESIGN | WM_USER+22 | Set the design-mode flag (SetDesign). |
| SFTMASKM_SETSELTEXT_A | WM_USER+23 | Replace the selected text (ANSI). |
| SFTMASKM_SETSELTEXT_W | WM_USER+24 | Replace the selected text (Unicode). |
| SFTMASKM_AUTOCOMPLETE_REFRESH | WM_USER+25 | Open or refresh the autocomplete window (AutoCompleteRefresh). |
| SFTMASKM_AUTOCOMPLETE_ADDBOTTOM | WM_USER+26 | Add a custom autocomplete entry at the bottom (AutoCompleteAddBottom). |
| SFTMASKM_AUTOCOMPLETE_ADDTOP | WM_USER+27 | Add a custom autocomplete entry at the top (AutoCompleteAddTop). |
| SFTMASKM_CALENDAR_SETBOLDDATE | WM_USER+28 | Set a bold date in the popup calendar (SetBoldDate). |
| SFTMASKM_CONTENTS_GETVALUE | WM_USER+29 | Retrieve a field value (GetValue). |
| SFTMASKM_CONTENTS_SETVALUE | WM_USER+30 | Set a field value (SetValue). |
| SFTMASKM_CONTENTS_GETDATETIME | WM_USER+31 | Retrieve the contents as a date/time value (GetDateTime). |
| SFTMASKM_CONTENTS_SETDATETIME | WM_USER+32 | Set the contents from a date/time value (SetDateTime). |
| SFTMASKM_GETINSERTPOSITION | WM_USER+33 | Calculate the closest valid insert position (GetInsertPosition). |
| SFTMASKM_SHOWDROPPOSITION | WM_USER+34 | Visualize the drop insert location (ShowDropPosition). |
| SFTMASKM_ACTIVATEINPUT | WM_USER+35 | Activate or deactivate data entry (ActivateInput). |
| SFTMASKM_ROLLUP | WM_USER+36 | Close any open popup window (Rollup). |
| SFTMASKM_SETDEFAULTVALUE | WM_USER+37 | Apply the default text to an empty control (SetDefaultValue). |
| SFTMASKM_GETTEXT | WM_USER+38 | Retrieve the contents (GetText). |
| SFTMASKM_SETTEXT | WM_USER+39 | Set the contents (SetText). |
| SFTMASKM_GETTEXT_A | WM_USER+40 | Retrieve the contents (ANSI). |
| SFTMASKM_SETTEXT_A | WM_USER+41 | Set the contents (ANSI). |
| SFTMASKM_GETTEXT_W | WM_USER+42 | Retrieve the contents (Unicode). |
| SFTMASKM_SETTEXT_W | WM_USER+43 | Set the contents (Unicode). |
| SFTMASKM_SETDARKMODE | WM_USER+44 | Set the dark mode setting (SetDarkMode). |
| SFTMASKM_GETDARKMODE | WM_USER+45 | Return the dark mode setting (GetDarkMode). |
| SFTMASKM_ISDARKMODEACTIVE | WM_USER+46 | Return whether dark mode rendering is active (IsDarkModeActive). |
| SFTMASKM_SETHIGHCONTRAST | WM_USER+47 | Set the high contrast setting (SetHighContrastMode). |
| SFTMASKM_GETHIGHCONTRAST | WM_USER+48 | Return the high contrast setting (GetHighContrastMode). |
| SFTMASKM_ISHIGHCONTRASTACTIVE | WM_USER+49 | Return whether high contrast rendering is active (IsHighContrastActive). |
| SFTMASKM_SETIMAGESCALING | WM_USER+50 | Set the image scaling setting (SetImageScaling). |
| SFTMASKM_GETIMAGESCALING | WM_USER+51 | Return the image scaling setting (GetImageScaling). |
| SFTMASKM_SETPIXELSCALING | WM_USER+52 | Set the pixel scaling setting (SetPixelScaling). |
| SFTMASKM_GETPIXELSCALING | WM_USER+53 | Return the pixel scaling setting (GetPixelScaling). |
| SFTMASKM_GETDPI | WM_USER+54 | Return the current monitor DPI (GetDPI). |
| SFTMASKM_AUTOCOMPLETE_SEED | WM_USER+56 | Add entries to the autocomplete save file (AutoCompleteSeed). |
The charset-neutral SftMask_* macros expand to the _A or _W message variant depending on the build's UNICODE setting.
See Also C/C++ API | Notifications
