I'm using a dialog similar to the on below (copied from another post).
Under 'case 5' (idle) I am checking to see if the Extra session window is still open. If not (user has closed it) then I also want to close the dialog box. I am setting FileDlgFunction = False, but the dialog box does not close. Any idea how to gracefully exit the 'dialog loop'?
What I am trying to do is shut down the dialog box if the user exits the Extra session first.
Under 'case 5' (idle) I am checking to see if the Extra session window is still open. If not (user has closed it) then I also want to close the dialog box. I am setting FileDlgFunction = False, but the dialog box does not close. Any idea how to gracefully exit the 'dialog loop'?
What I am trying to do is shut down the dialog box if the user exits the Extra session first.
Code:
Function FileDlgFunction(identifier$, action, suppvalue)
FileDlgFunction = True
Select Case action
Case 1 'dialog box initialized
Case 2 'button or control value changed
Select Case identifier
Case "BtnOk"
If DlgText$("NewPass") <> DlgText$("ConfNewPass") then
DlgText("ErrMsg"), "Passwords do not match."
Else
FileDlgFunction = False
End If
Case "BtnCancel"
FileDlgFunction = False
End Select
Case 3 'text or combo box changed
Case 4 'control focus changed
Case 5 'idle
DoEvents
End Select
End Function