Kinook Software Forum

Go Back   Kinook Software Forum > Visual Build Professional > [VBP] General Discussion
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 11-03-2009, 07:26 AM
wkwan wkwan is online now
Registered User
 
Join Date: 02-22-2008
Posts: 5
Unhappy Wait Hangs

I have two run program step calling a batch file on the remote computer, wait for completion is uncheck on both. I'm using 6.7a.
.
i.e. %DOSCMD% call c:\mybatch1.bat and %DOSCMD% call c:\mybatch2.bat


Run program 1
Run program 2
Wait <- hangs even if mybatch1.bat and mybatch2.bat window had closed on the remote machine.

This is what I use to get the process ID on both run program step.


Run program 1
------------------
Sub vbld_StepDone()

' store this step's process ID in temporary macro
vbld_TempMacros.Add "RUNPRG1_PROCESSID", vbld_TempMacro("RUNPROGRAM_PROCESSID").Value

End Sub

Run program 2
-------------------
Sub vbld_StepDone()

' store this step's process ID in temporary macro
vbld_TempMacros.Add "RUNPRG2_PROCESSID", vbld_TempMacro("RUNPROGRAM_PROCESSID").Value

End Sub

Wait
------
%RUNPRG1_PROCESSID%
%RUNPRG2_PROCESSID%
Reply With Quote
  #2  
Old 11-03-2009, 11:12 AM
kinook kinook is online now
Administrator
 
Join Date: 03-06-2001
Location: Colorado
Posts: 6,034
VBP v6 is no longer being supported or updated, but that works as expected in our tests w/ VBP 7.2a and PsExec 1.96. But be aware that this will only wait for the local PsExec processes to finish, not the remote batch file. To run two batch files remotely in parallel, you could put the two steps that call a batch file (configured to wait for completion) into separate .bld files, then use two VisBuildPro Project steps (configured to not wait for completion) to call them, followed by a Wait action.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



All times are GMT -5. The time now is 07:02 PM.


Copyright © 1999-2023 Kinook Software, Inc.