This code works fine in Extra Basic, but I can't get it to compile in VB. I posted it here because I know some of you have had experience with both and I'm not sure what needs to change or if I'll have to start from scratch.
Code:
Function dlgFunc(identifier$, action, suppvalue)
dlgFunc = True
Select Case action
Case 2
Select Case identifier$
Case "BtnOK"
If dlgValue("chkbox") = 1 Then dlgFunc = False
Case "Cancel"
dlgFunc = False
End Select
End Select
End Function
Sub Main
Begin Dialog dlgF 280, 50, "", .dlgFunc
Text 27, 8, 253, 10, "Use the checkbox to continue"
ButtonGroup .ButtonPressed
OkButton 87, 26, 50, 14, .BtnOK
CancelButton 143, 26, 50, 14
CheckBox 50, 26, 30, 14, "OK?", .chkbox
End Dialog
Dim dlgVar As dlgF
Chk = Dialog(dlgVar)
Select Case Chk
Case -1
MsgBox "Done"
Case 0
Exit Sub
End Select
End Sub