Simple concatenation fails
Posted: 18 Dec 2015 17:17
Hello,
I just try to concatenate the following variables:
@echo off
FOR /F "tokens=1,2,3 delims=." %%a in ("%date%") do set yy=%%c& set mm=%%b & set dd=%%a
set /a lastyear=%yy%-1
set output=IS_%lastyear%
echo %output%
_________________________
Output:
IS_
Output should be IS_2014
Can somebody help me?
I just try to concatenate the following variables:
@echo off
FOR /F "tokens=1,2,3 delims=." %%a in ("%date%") do set yy=%%c& set mm=%%b & set dd=%%a
set /a lastyear=%yy%-1
set output=IS_%lastyear%
echo %output%
_________________________
Output:
IS_
Output should be IS_2014
Can somebody help me?