luger Posted January 10, 2017 Share Posted January 10, 2017 (edited) Hello, My English is not good. #include <Process.au3> $Result = _RunDos("a"); Return 0 $Result2 = _RunDos("color a"); Return not 0 MsgBox(0, "Result", $Result) MsgBox(0, "Result", $Result2) There is a mistake here. Rundos_Help->Look Note: @AutoItVersion ;-->v3.3.14.2 Edited January 10, 2017 by luger Link to comment Share on other sites More sharing options...
TheDcoder Posted January 10, 2017 Share Posted January 10, 2017 That is because cmd.exe (command prompt) returned 1 (That means the call actually succeeded). Failure only occurs if the process/command was not able to execute, in this case, the command did execute. _RunDos is just a wrapper for cmd.exe (look at the code yourself). That means cmd.exe was successfully executed and therefore there is no failure here, hope I have cleared your doubt luger 1 EasyCodeIt - A cross-platform AutoIt implementation - Fund the development! (GitHub will double your donations for a limited time) DcodingTheWeb Forum - Follow for updates and Join for discussion Link to comment Share on other sites More sharing options...
luger Posted January 11, 2017 Author Share Posted January 11, 2017 (edited) On 10.01.2017 at 11:55 AM, TheDcoder said: That is because cmd.exe (command prompt) returned 1 (That means the call actually succeeded). Failure only occurs if the process/command was not able to execute, in this case, the command did execute. _RunDos is just a wrapper for cmd.exe (look at the code yourself). That means cmd.exe was successfully executed and therefore there is no failure here, hope I have cleared your doubt I wish there was a command giving a detailed result It was difficult to use Thanks for the answer.. Edited January 11, 2017 by luger Link to comment Share on other sites More sharing options...
TheDcoder Posted January 11, 2017 Share Posted January 11, 2017 18 minutes ago, luger said: I wish there was a command giving a detailed result Are you referring to the output made by the command? EasyCodeIt - A cross-platform AutoIt implementation - Fund the development! (GitHub will double your donations for a limited time) DcodingTheWeb Forum - Follow for updates and Join for discussion Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now