Hi,
This is the output:
C:\log>set input=
C:\log>if not exist "*.xml" (
echo No .xml files.
pause 1>nul
exit
)
C:\log>for /F "usebackq delims=" %I in (`dir /b /a:-d /o:-d *.xml`) do (
set input=%~nI
goto output
)
C:\log>(
set input=Test
goto output
)
C:\log>set output=
C:\log>for /F "usebackq tokens=4 delims='" %I in ("Test.xml") do (
set output=%I
goto copy
)
C:\log>copy "Test.pdf" "D:\.pdf"
The system cannot find the file specified.
C:\log>pause
Press any key to continue . . .
C:\log>
I created a folder called "log" in C:\ drive. And, placed two files
Test.xml
123.pdf
But, the program seems to be renaming the pdf with "Test".
Please look into the same., thanks