HeaderPane
Main
Hide

SftButton/DLL 3.0 - Button Control

Share Link
Print

Creating a Dialog Resource

This section describes how to add a button control to a dialog using Visual Studio.

Adding a Button Control to a Dialog

To add a SftButton/DLL control to a dialog, use the "Custom Control" toolbar button. Click on the button and then the dialog being designed to add a control.

Once a custom control has been added to a dialog, you can edit the control properties by using the View, Properties... menu command.

To define a SftButton/DLL control, enter the class SftButtonControl30 in the edit field labeled Class. Enter the button's label in the Caption field (optional; the label can also be set later through SFTBUTTON_CONTROL).

SftButton/DLL Control Styles

To enter a SftButton/DLL window style in the User Control Properties dialog, use the following list to add the desired style values and enter the resulting hexadecimal value in the field marked Style.

StyleValueDescription
WS_CHILD0x40000000Creates a child window. Usually required.
WS_DISABLED0x08000000Creates a button control that is initially disabled.
WS_GROUP0x00020000Specifies the first control of a group of controls.
WS_TABSTOP0x00010000Specifies a control that can receive the keyboard focus when the user presses the TAB key.
WS_VISIBLE0x10000000Creates a button control that is initially visible. Usually required.

The button control can be further customized at run-time by populating a SFTBUTTON_CONTROL structure and passing it to SftButton_SetControlInfo.

Test Mode

In the dialog test mode offered by Visual Studio, the SftButton/DLL control will not be displayed. Instead, a gray box will show the location of the control. When using the Tab key to test the tab stops, the simulated SftButton/DLL control will not receive the input focus and appear not to have a tab stop defined.


Last Updated 04/23/2026 - (email)
© 2026 Softel vdm, Inc.