I have file1.txt and test.bat in the same folder.
Inside test.bat:
This works:
SET test=file1.txt
COPY %test% file2.txt
This does not work:
IF ""=="" (
SET test=file1.txt
COPY %test% file2.txt
)
Why? The only difference is "if" statement.
Whats more interesting:
IF ""=="" (
COPY file1.txt file2.txt
)
works