Hey Guys and Gals,
This is Abdul again. I want to again thank those of you who have helped. This is kind of a repost because I'm still having trouble executing multiple scripts. This time, I'm including my code in hopes that it will clarify the situation and assist in any help you can provide. If I only execute 115200.wax, the script runs fine and the remote window also closes down at the end as expected. But if I try to run multiple scripts back to back, the remote terminal runs the first script, then my window runs the file_send.wax using my function RunTest but the other window never runs the second script "file_get". Any help would be appreciated.
proc main
string pwexe
integer handle2
long window2
clear
strfmt pwexe "%s\PW5.exe" $pwtaskpath
if run pwexe
pause 2
handle2 = $mainwin
if ddeinit window2 "PW5" "System" handle2
if ddeexecute window2 "EXECUTE 115200.wax"
pause 20
termmsg "Teminal Init Successful!`r`n"
RunTest ("Send File", "file_send.wax", A)
if ddeexecute window2 "EXECUTE File_Get.wax"
pause 5
termmsg "File Transfer Successful!`r`n"
else
termmsg "File Transfer Unsuccessful!?!`r`n"
endif
else
termmsg "Terminal Init Unsuccessful!?!`r`n"
endif
else
termmsg "Error initializing DDE channel`r`n"
endif
else
termmsg "Error running %s`r`n" pwexe
endif
ddeexecute window2 "PWEXIT"
ddeterminate window2
endproc
This is Abdul again. I want to again thank those of you who have helped. This is kind of a repost because I'm still having trouble executing multiple scripts. This time, I'm including my code in hopes that it will clarify the situation and assist in any help you can provide. If I only execute 115200.wax, the script runs fine and the remote window also closes down at the end as expected. But if I try to run multiple scripts back to back, the remote terminal runs the first script, then my window runs the file_send.wax using my function RunTest but the other window never runs the second script "file_get". Any help would be appreciated.
proc main
string pwexe
integer handle2
long window2
clear
strfmt pwexe "%s\PW5.exe" $pwtaskpath
if run pwexe
pause 2
handle2 = $mainwin
if ddeinit window2 "PW5" "System" handle2
if ddeexecute window2 "EXECUTE 115200.wax"
pause 20
termmsg "Teminal Init Successful!`r`n"
RunTest ("Send File", "file_send.wax", A)
if ddeexecute window2 "EXECUTE File_Get.wax"
pause 5
termmsg "File Transfer Successful!`r`n"
else
termmsg "File Transfer Unsuccessful!?!`r`n"
endif
else
termmsg "Terminal Init Unsuccessful!?!`r`n"
endif
else
termmsg "Error initializing DDE channel`r`n"
endif
else
termmsg "Error running %s`r`n" pwexe
endif
ddeexecute window2 "PWEXIT"
ddeterminate window2
endproc