So Im trying to use FORFILES dos command with autoit. Here is the command Forfiles /P C:\users /M *.txt /C "cmd /c ReplaceText @path yes no /I" Basically this will look at every .txt file in the C:\users directory and replace the word YES with the word NO using replacetext.vbs I can type this into a command window and it works great. However it does not work with autoit. Here is a simple command. Run(@ComSpec & " /c " & "FORFILES /P C:\Users") That command should show