06-22-2015 08:20 PM
I would like to have a non-modal dialog box run a script when I hit a "Load" button. Is this possible?
Thanks,
BG103
06-23-2015 02:00 AM
Hey BG103,
you can open a non modal SUD Dialog with the following exemplary code snippet:
Dim MyDlg If Nothing is SudNonModalDlgLst("Dlg1") Then Set MyDlg = SudDlgCreate("Dlg1",CurrentScriptPath & "TestDialog.sud") Else Set MyDlg = SudNonModalDlgLst("Dlg1") End If Call MyDlg.Show()
In this example I created a TestDialog.sud file with dialog "Dlg1".
In the SUD dialog you can create a button click event which runs ScriptStart function like this:
Sub Button1_EventClick(ByRef This) call ScriptStart(CurrentScriptPath & "TestScript.vbs") End Sub
Regards
Christian