So when I run this code:
@echo off
setlocal enabledelayedexpansion
set lstFolders= First Second
set intCounter=0
for %%i in (!lstFolders!) do (
set /a intCounter += 1
set strFlder=%%i
set strFolder!intCounter!=!strFlder!
echo %%i
echo !strFlder!
echo !strFolder%intCounter%!
echo !strFolder1!
echo !strFolder2!
)
:End
pause
endlocal
It results with this:
First
First
ECHO is off.
First
ECHO is off.
Second
Second
ECHO is off.
First
Second
Why doesn't it allow me to echo the variable create with the format : !strFolder%intCounter%!
? Is there another way to reference this variable and get the data that is inside of it?