Sign in with
Sign up | Sign in
Your question

Killing an Application/Process via a Batch File

Last response: in Windows XP
Share
March 14, 2005 1:29:15 PM

Archived from groups: microsoft.public.windowsxp.security_admin (More info?)

G'Day,
I want to limit a child's access to a game to certain times.
It's only a simple Application, so I thought two Batch Files may work:
1. To extract the Program Files from a ZIP (she's not yet savvy enough to do
this herself).
2. To delete the Program Files.
By running these two files via Task Scheduler I'd be able to regulate her
access.

However, if she's still playing the game at the time the program files are
to be deleted, I assume that this idea won't work (i.e. can't delete a file
in use).

So can anyone help me kill the actual application/process through a Batch
File?

Or has anyone got a better method altogether?

Cheers.
Anonymous
March 14, 2005 4:25:48 PM

Archived from groups: microsoft.public.windowsxp.security_admin (More info?)

Michael wrote:

> G'Day,
> I want to limit a child's access to a game to certain times.
> It's only a simple Application, so I thought two Batch Files may work:
> 1. To extract the Program Files from a ZIP (she's not yet savvy enough to do
> this herself).
> 2. To delete the Program Files.
> By running these two files via Task Scheduler I'd be able to regulate her
> access.
>
> However, if she's still playing the game at the time the program files are
> to be deleted, I assume that this idea won't work (i.e. can't delete a file
> in use).
>
> So can anyone help me kill the actual application/process through a Batch
> File?
Hi

A)
If you have Windows XP Professional the builtin taskkill.exe
is an option. In a command prompt, run taskkill.exe /? for help.


B)
Some freeware command line tools that can be used for Windows XP Home/Pro:

PsKill.exe in the free PsTools suite at
http://www.sysinternals.com/

Cmdow.exe
http://www.commandline.co.uk/cmdow/index.html


--
torgeir, Microsoft MVP Scripting and WMI, Porsgrunn Norway
Administration scripting examples and an ONLINE version of
the 1328 page Scripting Guide:
http://www.microsoft.com/technet/scriptcenter/default.m...
March 18, 2005 11:01:04 AM

Archived from groups: microsoft.public.windowsxp.security_admin (More info?)

"Torgeir Bakken (MVP)" <Torgeir.Bakken-spam@hydro.com> wrote in message
news:ulRLQEJKFHA.3908@TK2MSFTNGP10.phx.gbl...
> Michael wrote:
>
>> G'Day,
>> I want to limit a child's access to a game to certain times.
>> It's only a simple Application, so I thought two Batch Files may work:
>> 1. To extract the Program Files from a ZIP (she's not yet savvy enough to
>> do this herself).
>> 2. To delete the Program Files.
>> By running these two files via Task Scheduler I'd be able to regulate her
>> access.
>>
>> However, if she's still playing the game at the time the program files
>> are to be deleted, I assume that this idea won't work (i.e. can't delete
>> a file in use).
>>
>> So can anyone help me kill the actual application/process through a Batch
>> File?
> Hi
>
> A)
> If you have Windows XP Professional the builtin taskkill.exe
> is an option. In a command prompt, run taskkill.exe /? for help.
>
>
> B)
> Some freeware command line tools that can be used for Windows XP Home/Pro:
>
> PsKill.exe in the free PsTools suite at
> http://www.sysinternals.com/
>
> Cmdow.exe
> http://www.commandline.co.uk/cmdow/index.html
>
>
> --
> torgeir, Microsoft MVP Scripting and WMI, Porsgrunn Norway
> Administration scripting examples and an ONLINE version of
> the 1328 page Scripting Guide:
> http://www.microsoft.com/technet/scriptcenter/default.m...

Thanks. Big help.
!