Another method which I am using is a move command:
Code: Select all
move /y a.a a.a >nul 2>nul
returns ERRORLEVEL 1 if file is locked, 0 if not locked.
Saso
Code: Select all
move /y a.a a.a >nul 2>nul
Code: Select all
set tmpstring="String with ^^ character"
Code: Select all
set "oldname=<oldname.txt"
Code: Select all
FOR /F %%i IN (oldname.txt) DO set oldname=%%i
Code: Select all
if "%input%"=="" echo Empty string entered.