feldmaneyal Posted May 14, 2005 Posted May 14, 2005 I need to get the process ID and pass it to another application I was able to put the PID in a msgbox - but I need it in a command line means that I would like to Run AI and get 0 if the process not exist or the PID if exist $PID = ProcessExists("notepad.exe") return ($PID) In the dos level - get nothing. Please advise, Thx in advance., Eyal
Ejoc Posted May 14, 2005 Posted May 14, 2005 exit($PID) Start -> Programs -> AutoIt v3 -> AutoIt Help File -> Index -> (The Function you are asking about)----- Links -----DllStruct UDFsRSA Crypto UDFs
feldmaneyal Posted May 14, 2005 Author Posted May 14, 2005 Hi, it doesnt work any other idea? $PID = ProcessExists("notepad.exe") exit($PID) I run like c:\\pid.au3 or pid.exe Get nothing on the dos prompt thx
GaryFrost Posted May 14, 2005 Posted May 14, 2005 you won't get anything on the dos prompt, you have to catch the errorlevel from dos if i remember correctly. SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
GaryFrost Posted May 14, 2005 Posted May 14, 2005 (edited) read up on errorlevel in windows help if you plan to catch it by batch file or read up on EnvGet in AutoIt help Edited May 14, 2005 by gafrost SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
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