I have a batch file and I want to include an external file containing some variables (say configuration variables). Is it possible?
If the external configuration file is also valid batch file, you can just use:
call externalconfig.bat
inside your script. Try creating following a.bat:
@echo off call b.bat echo %MYVAR%
and b.bat:
set MYVAR=test
Running a.bat should generate output:
test