The batch file dummy_sql.bat:
!include nsDialogs.nsh
Var Dialog
Var Log
OutFile show_bat.exe
Page custom runScriptsPage leaveRunScriptsPage
Section -Main
SectionEnd
Function runScriptsPage
#Create dialog and show.
nsDialogs::Create 1018
Pop $Dialog
${NSD_CreateListBox} 0 20 100% 100u $Log
Pop $Log
nsDialogs::Show
#Run the batch file, send the output to the listbox.
FindWindow $0 "#32770" "" $HWNDPARENT
GetDlgItem $1 $0 1200 #Get the window handle for the ListBox
ExecDos::exec /NOUNLOAD /TOWINDOW "dummy_sql.bat" "" $1
FunctionEnd
Function leaveRunScriptsPage
FunctionEnd
I guess I'm doing more than one thing wrong. Any help would be appreciated.
@ECHO OFF
ECHO wait
SLEEP 5
ECHO done
Tim