OS. To add the dialog buttons
The last step in defining the dialog is to add the OK and Cancel buttons.
- Click the Add OK Button tool.
- Click a point near the bottom, right corner of the form. The OK button is placed.
- Click the Add Cancel Button tool.
- Click a point to the right of the OK button. The Cancel button is placed.
- (Optional) Either:
- Select the Save and Exit tool. The UserDialog Editor closes.
The dialog
definition code is added to your macro:
Begin Dialog UserDialog 600,200,"2D Frame Model" ' %GRID:5,5,1,1
Text 20,20,190,15,"No. of Horizontal Bays:",.Text1
Text 20,45,190,15,"No. of Vertical Bays",.Text2
Text 20,70,190,15,"Vertical Distance",.Text3
Text 20,95,190,15,"Horizontal Distance",.Text4
Text 20,130,190,15,"Support Type",.Text5
TextBox 220,20,130,15,.clmn
TextBox 220,40,130,15,.row
TextBox 220,70,130,15,.ht
TextBox 220,95,130,15,.wdth
OptionGroup .sprt
OptionButton 220,130,90,15,"Fixed",.OptionButton1
OptionButton 370,130,90,15,"Pinned",.OptionButton2
OKButton 360,165,90,20
CancelButton 490,165,90,20
End Dialog
Dim dlg As UserDialog
Dialog dlg