The next figure shows the batch file that is used in the run-commands file (step 5) to start the tn3270
sessions.
@ECHO OFF
REM *******************************************************************************************
REM Start master console and wait for connection to Hercules
REM *******************************************************************************************
START /D "C:\Program Files (x86)\TomBrennanSoftware\VistaTN3270" VistaTN3270.EXE MVS38J_MST.SES
CHOICE /t 1 /d y
REM ******************************************************************************************
REM Start operator console and wait for connection to Hercules
REM *******************************************************************************************
START /D "C:\Program Files (x86)\TomBrennanSoftware\VistaTN3270" VistaTN3270.EXE MVS38J_OPR.SES
CHOICE /t 1 /d y
REM *******************************************************************************************
REM Start TSO terminals and wait for connection to Hercules
REM *******************************************************************************************
START /D "C:\Program Files (x86)\TomBrennanSoftware\VistaTN3270" VistaTN3270.EXE MVS38J_TSO.SES
CHOICE /t 1 /d y
START /D "C:\Program Files (x86)\TomBrennanSoftware\VistaTN3270" VistaTN3270.EXE MVS38J_TSO.SES
EXIT
Figure 351: Batch file to start tn3270 sessions
The CHOICE command used in the batch file is to issue a delay before trying to connect the next tn3270
session.
The “/t” parameter specifies the number of seconds to pause before a default choice is made. Option “/d”
specifies the default choice that is issued after the timeout has expired. The character given as argument
must be in the set of choices specified by the “/c” option (defaults are ‘Y’ and ‘N’).