Dim complete
Function DlgFunc(identifier$, action, suppvalue)
DlgFunc = true
Select Case action
Case 1 'DlgOpened
DlgVisible "ButtonJunk",0
DlgText "TextBox1",Temp
DlgText "TextBox2",Temp
DlgText "TextBox3",arg_1
DlgText "TextBox4",arg_2
DlgText "TextBox5",arg_3
DlgText "TextBox6",arg_4
DlgText "TextBox7",arg_5
DlgText "TextBox8",arg_6
DlgText "TextBox9",arg_7
Case 2 'Button/Text Changed
Select Case identifier$
Case "ButtonOK","ButtonCancel"
DlgFunc = False
End Select
End Select
End Function
Sub YourDlg
Begin Dialog newdlg 95, 12, 305, 204, "Zero Rin Not Issued Adcorr Letter", .DlgFunc
TextBox 74, 23, 56, 12, .TextBox1
TextBox 185, 25, 80, 12, .TextBox2
TextBox 170, 55, 92, 12, .TextBox3
TextBox 170, 70, 92, 12, .TextBox4
TextBox 170, 85, 92, 12, .TextBox5
TextBox 170, 100, 92, 12, .TextBox6
TextBox 170, 115, 92, 12, .TextBox7
TextBox 170, 130, 92, 12, .TextBox8
TextBox 170, 145, 92, 12, .TextBox9
PushButton 1, 1, 1, 1, "", .ButtonJunk
PushButton 68, 173, 50, 14, "OK", .ButtonOK
Text 5, 10, 211, 12, "Please fill in the boxes with the stated information and click OK."
CancelButton 165, 173, 50, 14, .ButtonCancel
Text 38, 26, 28, 12, "Corp Id"
Text 142, 27, 36, 12, "RPE Date"
Text 43, 55, 93, 12, "Total Credits and Payments"
Text 43, 70, 48, 12, "Total Allowance"
Text 43, 85, 82, 12, "Total Penalties"
Text 43, 100, 75, 12, "Amount Crdtd Est Allow"
Text 43, 115, 85, 12, "Amt appld Other Bal Due"
Text 43, 130, 51, 12, "Interest Allowed"
Text 43, 145, 47, 12, "Total Allowance"
End Dialog
Dim mydialog as newdlg
On Error Resume Next
Dialog mydialog
If Err = 102 then
'Handle the cancelled window here
End If
End If
Sub Main
YourDlg
End Sub