Check boxes

<< Click to Display Table of Contents >>

Check boxes

Check boxes are suitable for "Yes/No" or "On/Off" choices.

dialog_check

Syntax:        CheckBox X, Y, Width, Height, Text, .ID

ID is a variable that contains the current state.

Example:

Sub Main

 Begin Dialog CheckSample 15, 32, 149, 96, "Check boxes"

         OKButton 92, 8, 40, 14

         CancelButton 92, 32, 40, 14

         CheckBox 12, 8, 60, 8,  "Check box 1", .CheckBox1

         CheckBox 12, 24, 60, 8, "Check box 2", .CheckBox2

         CheckBox 12, 40, 60, 8, "Check box 3", .CheckBox3

         CheckBox 12, 56, 60, 8, "Check box 4", .CheckBox4

 End Dialog

 Dim Dlg1 As CheckSample

 rc% = Dialog(Dlg1)

End Sub