cmd = dir /b C:\Dir\To\Scan\*.bat dir: /b: No such file or directory dir: C:DirToScan*.bat: No such file or directory