Instead of moving all *.txt
and .exe
files at the same time - why not use a for loop to move them individually?
for %%a in (*.%~2) do move %%a ..\..\%~1\ || echo %%a>>fail.log
The code after ||
will only run if an error level is set by the move command.