aquila Posted July 15, 2008 Share Posted July 15, 2008 (edited) Hello, I added some files to an array and now i want to check the syntax of them. In Cmd you can say if you are in the autoit3 directory: "au3check file.au3" and it will return the result. Is it possible to run cmd with this parameters with autoit? Because i want to check every file and i want to get out the result with stdoutread. greetz Edit: Well, but there is the problem. I don't know how to call it with the parameters muttley Edited July 15, 2008 by aquila Link to comment Share on other sites More sharing options...
Richard Robertson Posted July 15, 2008 Share Posted July 15, 2008 You can call the program, yes. It works just like any other program. Link to comment Share on other sites More sharing options...
aquila Posted July 15, 2008 Author Share Posted July 15, 2008 $cmd = Run(@ComSpec & '/c C:\Programme\Autoit3\au3check.exe C:\test.au3', "", @SW_SHOW) MsgBox(0, "", StdoutRead($cmd)) So, why doesn't it work? Can someone make it correctly? Link to comment Share on other sites More sharing options...
Skruge Posted July 15, 2008 Share Posted July 15, 2008 (edited) @Edit: (Left out the StdOutRead stuff) See zorphnog's post Edited July 15, 2008 by Skruge [font="Tahoma"]"Tougher than the toughies and smarter than the smarties"[/font] Link to comment Share on other sites More sharing options...
zorphnog Posted July 15, 2008 Share Posted July 15, 2008 Try this: #include <Constants.au3> Local $cmd = Run(@ComSpec & ' /c Au3Check.exe C:\test.au3', "C:\Programme\AutoIt3\", @SW_HIDE, $STDOUT_CHILD) Local $line While 1 $line = StdoutRead($cmd) If @error Then ExitLoop If $line <> "" Then MsgBox(4096, "", $line) WEnd 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