I have discovered the source of the "bad command or file name". It was not QEMM at all, but ARACHNE.BAT . ARACHNE.BAT contains the following 2 lines: %TEMP%\$roura$.bat if exist %TEMP%$roura$.bat %TEMP%$roura$.bat I amended the first line: if exist %TEMP%\$roura$.bat %TEMP%\$roura$.bat if exist %TEMP%$roura$.bat %TEMP%$roura$.bat At work, where I don't see "b c or f n", my TEMP variable points to C:\TEMP . So the original first line above is valid, because it evaluates to C:\TEMP\$roura$.bat . But at home where I was getting the odd effect, my TEMP is D:\ . So ARACHNE.BAT was trying to call D:\\$roura$.bat on the first line. That generated the error, but then the second line called on D:\$roura$.bat , which ran correctly. Making the first line conditional, as the second one was to begin with, solved the problem.
