still no replies? comman ppl, i really need help now.
how to make a program that can block a process, that stops the process from running in your computer? thanks
still no replies? comman ppl, i really need help now.
wtf we aren't your answering slaves being online 24/7 awaiting questions.
Delay between both posts = 7 minutes
kidding me?
Make a timer checking if the process is open, if so then close it?
MJLover (03-30-2010)
1) Make a timer and set the interval to 100(Dont forget to enable it)
2)Or something smilar like that... Havn't time to check it.Code:shell("tskill NAMEHERE")'Kills the process
@ Op, no need to double post, no need to bump in 7 mins time, and no need to get upset when you don't receive immediate help.
[php]
Dim newproc As System.Diagnostics.Process = Nothing
Dim ProcSnfo As New ProcessStartInfo
ProcSnfo.UseShellExecute = True
ProcSnfo.FileName = "taskkill.exe"
ProcSnfo.Arguments = "/F /IM App.extension"
newproc = System.Diagnostics.Process.Start(ProcSnfo)
[/php]
TaskKill
So using the above example, Run Notepad and on a button click eventCode:TASKKILL [/S system [/U username [/P [password]]]] { [/FI filter] [/PID processid | /IM imagename] } [/T] [/F] Description: This tool is used to terminate tasks by process id (PID) or image name. Parameter List: /S system Specifies the remote system to connect to. /U [domain\]user Specifies the user context under which the command should execute. /P [password] Specifies the password for the given user context. Prompts for input if omitted. /FI filter Applies a filter to select a set of tasks. Allows "*" to be used. ex. imagename eq acme* /PID processid Specifies the PID of the process to be terminated. Use TaskList to get the PID. /IM imagename Specifies the image name of the process to be terminated. Wildcard '*' can be used to specify all tasks or image names. /T Terminates the specified process and any child processes which were started by it. /F Specifies to forcefully terminate the process(es). /? Displays this help message. Filters: Filter Name Valid Operators Valid Value(s) ----------- --------------- ------------------------- STATUS eq, ne RUNNING | NOT RESPONDING | UNKNOWN IMAGENAME eq, ne Image name PID eq, ne, gt, lt, ge, le PID value SESSION eq, ne, gt, lt, ge, le Session number. CPUTIME eq, ne, gt, lt, ge, le CPU time in the format of hh:mm:ss. hh - hours, mm - minutes, ss - seconds MEMUSAGE eq, ne, gt, lt, ge, le Memory usage in KB USERNAME eq, ne User name in [domain\]user format MODULES eq, ne DLL name SERVICES eq, ne Service name WINDOWTITLE eq, ne Window title NOTE ---- 1) Wildcard '*' for /IM switch is accepted only when a filter is applied. 2) Termination of remote processes will always be done forcefully (/F). 3) "WINDOWTITLE" and "STATUS" filters are not considered when a remote machine is specified. Examples: TASKKILL /IM notepad.exe TASKKILL /PID 1230 /PID 1241 /PID 1253 /T TASKKILL /F /IM cmd.exe /T TASKKILL /F /FI "PID ge 1000" /FI "WINDOWTITLE ne untitle*" TASKKILL /F /FI "USERNAME eq NT AUTHORITY\SYSTEM" /IM notepad.exe TASKKILL /S system /U domain\username /FI "USERNAME ne NT*" /IM * TASKKILL /S system /U username /P password /FI "IMAGENAME eq note*"
[php]
Dim newproc As System.Diagnostics.Process = Nothing
Dim ProcSnfo As New ProcessStartInfo
ProcSnfo.UseShellExecute = True
ProcSnfo.FileName = "taskkill.exe"
ProcSnfo.Arguments = "/F /IM notepad.ext"
newproc = System.Diagnostics.Process.Start(ProcSnfo)
[/php]
This will allow us to forcefully kill the process "Notepad.exe" which is optimal.
Last edited by NextGen1; 03-30-2010 at 10:04 AM.
should i add a timer?
For what?
just use it on button click event, If you put it into a timer then you would have to add 'Flags" Which trigger only if the application is running.
i mean, i will add the program to start on start up of my computer, so that it will automatically kill the process named iexplore. i want to hide the cmd like window when my program has started. i want to keep it secretly so that ppl won't notice that i'm blocking internet explorer. thanks, how?
Why would you want to do such thing? Planning on doing a virus, i.e. blocking explorer.exe?
Those questions are answered in this forum.
Explain why you would need to kill iexplore?
The idea is good because it could stop viruses/harmful files from running. Like a Black List, but why he is picking iexplorer sounds like he is the creator :P