04-13-2023 06:22 AM - edited 04-13-2023 06:23 AM
Hi, I have some code in a script that creates a Sud Dialog (SudDlgCreate("Dlg1",...). However, when I want to run the script again it complains that:
"A dialog box called "DLG1" already exist."
Is there any way to check if the Dlg1 already exists? Like this:
If Dlg1 = 0 Then
Set MyDlg = SudDlgCreate("Dlg1","C:\Temp\QuickTools.sud")
Thanks in advance
/Mike
Solved! Go to Solution.
04-13-2023 10:35 AM
Worth trying
Dim i
For i = 1 to SudNonModalDlgCount
if SudNonModalDlgLst(i).DialogCode = "Dlg1" Then
Call MsgBoxDisp(SudNonModalDlgLst(i).DialogCode & " Exists")
end if
Next
04-14-2023 01:47 AM
Thank you, it works perfect!