I want to run Batch file 1(Path C:\3rdparty\Test\App) from Batch file 2(C:)
and VS2008.sln is there in C:\3rdparty\Test\App\VS2008
Batch File 1
REM BatchFile1.bat
set DEVENV_PATH=%VS90COMNTOOLS%..\IDE
REM ---------------------------------------------------------------------
set OUTDIR=.\output\windows\x86
rmdir /S /Q %OUTDIR%
mkdir %OUTDIR%
call "%DEVENV_PATH%\devenv.com" VS2008\VS2008.sln /Rebuild "Release|Win32"
call "%DEVENV_PATH%\devenv.com" VS2008\VS2008.sln /Rebuild "Debug|Win32"
REM ---------------------------------------------------------------------
set OUTDIR=.\output\windows\x64
rmdir /S /Q %OUTDIR%
mkdir %OUTDIR%
call "%DEVENV_PATH%\devenv.com" VS2008\VS2008.sln /Rebuild "Release|x64"
call "%DEVENV_PATH%\devenv.com" VS2008\VS2008.sln /Rebuild "Debug|x64"
REM ---------------------------------------------------------------------
echo "BatchFile1.bat completed."
Batch File 2
echo "Running Batch File 2"
call C:\3rdparty\Test\App\BatchFile1.bat
Here when batchfile1 is called from Batchfile2 it is not able to execute VS2008.sln since path is different.
I Don’t want to change batchfile1.Is it possible to do changes in batch file 2 to execute the Batch file1.
Try changing the directory to the directory of BatchFile1.