Jump to content

darweet

Members
  • Posts

    2
  • Joined

  • Last visited

Everything posted by darweet

  1. Thank you for the replies @javiwhite and @pcjunki ! At the end of the day I found out the problem. Turned out AutoIT was looking for PsExec.exe in 64-bit format. In another post I found a solution: DllCall("kernel32.dll", "int", "Wow64DisableWow64FsRedirection", "int", 1) ;Prevent autoIT to look for 64-bit psexec.exe After I added this line before where i call the batch file, everything works fine. Anyway thanks for the replies guys!
  2. Hi all, so I've been trying to write a script that'll run a local .bat file. It's a simple idea that i run a batch file from autoit using the codes below with a simple run command. #RequireAdmin Run( 'C:\AutoTestPackage\TestSuite\SmokeTest\Configure\Temp_Basic.bat' ) Then the batch file will execute the command line psexec -i -d \\SGP101TEST02 -u TEST02 -p admin3t -f -c C:\AutoTestPackage\TestSuite\SmokeTest\Configure\Basic_Configuration.bat However when i run the script below, the cmd window would appear but it gives an error saying 'psexec.exe' is not recognized as an internal or external command. I also tried directly writing this in autoit Run( @ComSpec & " /k C:\Windows\System32\PsExec.exe \\SGP101TEST02 C:\AutoTestPackage\TestSuite\SmokeTest\Configure\Temp_Basic.bat > C:\Temp\My.log") But same error Can anyone tell me what was going on? Btw if i run the .bat manually it worked!
×
×
  • Create New...