If you have defined one or more data sets within your program, as discussed in Working with Data at the Program Level, the data items from the corresponding FD are listed in the Screen Designer Drag and Drop pop-up window. This window also lists Working-Storage, Linkage, and other data items defined in your program.
By default, this interface lists the field names as they are declared in the program. If, however, you have used the XFD tab of the File Designer to assign a Name directive to a field, you can elect to have that name appear in the Drag and Drop interface instead of the field name. When you choose this option, the Title property for any control that has a Name directive will show that name, rather than the actual field name. For information about enabling this option, see Designing a Custom XFD.
The Drag and Drop interface allows you to select a control type and one or more data items, then draw the control on the screen. AcuBench automatically adds the data item to the control's Property sheet as a Value Variable, generated Screen Section code to assign the item as the control's VALUE property. In addition, if you select a combo box, grid, list box, paged grid, or paged list box control type, additional code is generated to populate the control with data when the screen is loaded. These controls, referred to as autoload controls, are discussed in Creating Autoload Controls.
To use the Drag and Drop window to add controls to your screen:
In most cases, when you release the mouse button, the control(s) is/are drawn on the screen. If you have chosen either a radio button control or one of the autoload control types, a second interface appears, allowing you to configure the behavior of the selected control. In these circumstances, when you click OK in the secondary interface, the control is drawn on the screen.
Radio button controls are used when the user must select one and only one of a series of options. As a result, each individual radio button control is placed within a group, and the run-time ensures that only one member of the group at a time can be selected.
When you use Drag-and-Drop to create a radio button, the initial steps are the same as any other control. You select a control type and a data item, then drag the data item to the screen. When you do this, the Make Radio Button dialog box appears.
This interface represents a group of radio buttons. You add individual radio button controls to the group corresponding to each of the available options.
To add items to the group of radio buttons:
The name listed here is assigned as the control’s title, which appears next to the radio button on the screen.