Jump to content

Array Specialist required


Recommended Posts

Here is what has to be done. I had to use a very ugly work-around in Ver2

1st array

$RP has to contain all of the running processes on the system. It probably needs to use ProcessExists but how to get them all into an array?

2nd array

$PP has to contain a list of processes that can not be closed.

This will be hard coded items like SYSTRAY.EXE, RUNDLL32.EXE &etc.

The final outcome is that I use ProcessClose to force all processes that are not listed in $PP to close.

So the problems are, how to best create the array for $RP and how to check $RP against $PP when using ProcessClose.

If you have a problem with the concept, think EndItAll2. I had to use 3rd party software the last time and I don't want to do that since we now have process control in ver.3

Edited by GEOSoft

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

  • 7 months later...

Are you still looking to figure this out? I have something very similar scripted using pslist from Sysinternals. Its another 3rd party app I know but I'm only using it to dump out to a txt file. Either way, let me know and I'll dig it up.

Scooby

Link to comment
Share on other sites

  • 1 month later...

Use pv.exe from http://www.teamcti.com/pview/ it is the best for killing, viewing, etc. processes. You can pipe output from the program to a text file and then parse the text file.

RunWait(@ComSpec & ' /c "' & @TempDir & '\pv.exe" -l>>"C:\proclist.txt"', '', @SW_HIDE)
.

Will give you the list of running processes with the commandlines used to launch them.

<{POST_SNAPBACK}>

Jon solved the problem with the process functions. I was doing it by piping the output from TList.exe to a text file and then parsing that. Now I don't even have to include an extra file.

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...