I have a batch file which is in a directory and must be run from there as well because it updates files within this directory. This works perfectly fine, except when t
Better than cd is pushd which will
cd
pushd
D:\...
So pushd %~dp0 is good.
pushd %~dp0
Good practice is then to call popd when done.
popd