Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rutgers!sri-unix!ctnews!pyramid!hplabs!hp-pcd!hpcvlo!bill From: bill@hpcvlo.HP.COM (Bill Frolik) Newsgroups: comp.sys.ibm.pc Subject: Re: batch files calling batch files Message-ID: <1610013@hpcvlo.HP.COM> Date: Fri, 24-Apr-87 11:02:14 EDT Article-I.D.: hpcvlo.1610013 Posted: Fri Apr 24 11:02:14 1987 Date-Received: Sun, 26-Apr-87 22:37:16 EDT References: <626@cod.UUCP> Organization: Hewlett-Packard Co., Corvallis, OR, USA Lines: 22 To call another batch file from within a batch file, just invoke another copy of COMMAND.COM with a /C switch: ... echo This batch file calls "whatever.bat" command /c whatever.bat arg1 arg2 arg3 ... echo We return to here ... Be aware that since you are invoking a new command interpreter, the called batch file will live in a new "environment" (i.e., any variables that you have SET will not exist to the called file, and any variables that it SETs will disappear when control returns to the caller). DOS 3.3 has a new CALL command that lets you do batch file calling without having to do "command /c". Bill Frolik hp-pcd!bill Hewlett-Packard Portable Computer Division Corvallis, Oregon