Skip to main content

script to terminate the process

More
17 years 2 weeks ago #21230 by yadav
i got one doubt....we have an windows 2003 server our company in that we have installed some applications,when we login to the system and if we open task manager some applications like crasos.exe,HPGS2WNF.exe are running these are related to some applications what we have installed...the only way to terminate this process is using task manager.....but i wrote some logon script to terminate that process ......but its not working can u help me regarding this



thank you,
prasad yadav
More
16 years 11 months ago #21674 by wrecklesswun
Replied by wrecklesswun on topic msconfig
Use the msconfig utility to disable the associated application that starts up. Is the login script you are running run as the user or machine?
More
16 years 11 months ago #22041 by Bionicthumb
I agree with wrecklesswun about disabling the application from starting, but if you want a script...


[code:1]
setlocal
:START
tasklist | find /I "HPGS2WNF.exe"
set myerrorlevel=%errorlevel%
if %myerrorlevel% equ 0 taskkill /F /IM "HPGS2WNF.exe"
if %myerrorlevel% neq 0 ping 233.233.233.233 -w 1000 -n 2 & goto :START
[/code:1]

Save it with a .bat extension and place it in your user's "startup" directory in the start menu. The ping command is there to control the looping so that it doesn't consume 100% of the CPU.
Time to create page: 0.155 seconds