473,399 Members | 3,832 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

task manager, app doesn't unload

on my developing system, when my app exits, it always gets removed withing a
second from the task manager. on my clients machine, the app exits but stays
indefinitely in the task manager.

i tried every which way to kill the process, i did all of the following to
no avail:

in the module whose sub main loads the form and then starts
Application.Run(), i made an exit sub, in whichi set the app form to
Nothing, i set the apps class to nothing, t then lookd for the apps process
to kill it by

Dim proc, procs() As Process

procs = Process.GetProcessesByName("MyAppName")

For Each proc In procs

proc.Kill()

Next

and finally i ended with

Application.Exit()

and still the app lives on in the task manager and eats up resouces, though
i can't see how it is running

without hiring a hitman, how do i kill off this app?

ray


Dec 6 '06 #1
4 1290
"ray well" <no****@nospam.comwrote in message
news:u%******************@TK2MSFTNGP05.phx.gbl...
on my developing system, when my app exits, it always gets removed withing
a
second from the task manager. on my clients machine, the app exits but
stays
indefinitely in the task manager.

i tried every which way to kill the process, i did all of the following to
no avail:

in the module whose sub main loads the form and then starts
Application.Run(), i made an exit sub, in whichi set the app form to
Nothing, i set the apps class to nothing, t then lookd for the apps
process
to kill it by

Dim proc, procs() As Process

procs = Process.GetProcessesByName("MyAppName")

For Each proc In procs

proc.Kill()

Next

and finally i ended with

Application.Exit()

and still the app lives on in the task manager and eats up resouces,
though
i can't see how it is running

without hiring a hitman, how do i kill off this app?
All of which begs the question as to why you need to do this. Kill() is a
last resort. It should be used sparingly.

With such a mindless loop can you really be certain that you are not
killing, or trying to kill, something important?

Is it that you are trying to shutdown the system? If so, there are better
ways.

Regards,
Will
Dec 6 '06 #2

"William DePalo [MVP VC++]" <wi***********@mvps.orgwrote in message
news:ua**************@TK2MSFTNGP04.phx.gbl...
"ray well" <no****@nospam.comwrote in message
news:u%******************@TK2MSFTNGP05.phx.gbl...
>on my developing system, when my app exits, it always gets removed
withing a
second from the task manager. on my clients machine, the app exits but
stays
indefinitely in the task manager.

i tried every which way to kill the process, i did all of the following
to
no avail:

in the module whose sub main loads the form and then starts
Application.Run(), i made an exit sub, in whichi set the app form to
Nothing, i set the apps class to nothing, t then lookd for the apps
process
to kill it by

Dim proc, procs() As Process

procs = Process.GetProcessesByName("MyAppName")

For Each proc In procs

proc.Kill()

Next

and finally i ended with

Application.Exit()

and still the app lives on in the task manager and eats up resouces,
though
i can't see how it is running

without hiring a hitman, how do i kill off this app?

All of which begs the question as to why you need to do this. Kill() is a
last resort. It should be used sparingly.

With such a mindless loop can you really be certain that you are not
killing, or trying to kill, something important?
No, the OP is trying to kill only applications with a particular process
name ("MyAppName").

Try attaching a debugger to the zombie task and see what threads are running
and where.
>
Is it that you are trying to shutdown the system? If so, there are better
ways.

Regards,
Will

Dec 7 '06 #3
"Ben Voigt" <rb*@nospam.nospamwrote in message
news:OA**************@TK2MSFTNGP06.phx.gbl...
>With such a mindless loop can you really be certain that you are not
killing, or trying to kill, something important?

No, the OP is trying to kill only applications with a particular process
name ("MyAppName").
My bad. Well then that's better.

Still, if the target is something written by the OP there are better ways to
go.

And if it is not, it's at best rude, at worst risky.

Regards,
Will
Dec 7 '06 #4

"William DePalo [MVP VC++]" <wi***********@mvps.orgwrote in message
news:uU**************@TK2MSFTNGP03.phx.gbl...
"Ben Voigt" <rb*@nospam.nospamwrote in message
news:OA**************@TK2MSFTNGP06.phx.gbl...
>>With such a mindless loop can you really be certain that you are not
killing, or trying to kill, something important?

No, the OP is trying to kill only applications with a particular process
name ("MyAppName").

My bad. Well then that's better.

Still, if the target is something written by the OP there are better ways
to go.
I believe the OP already said the app had been told to exit, but it was
hanging. He needs to attach a debugger to the app while it's hung to find
out what went wrong in the exit path.
>
And if it is not, it's at best rude, at worst risky.

Regards,
Will


Dec 8 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Jaans | last post by:
I have a problem that relates to running "cleanup" code when an application is forcibly ended using the "End Process" of "Task Manager" (Please note that this is very different from "End Task"...
2
by: ramialhasan | last post by:
I got used to use VB ACTIVEX EXEs and when using the compiled EXE and instantiate it the EXE name appears on both tabs of Task Manager(Applications and Processes). But when using the ATL EXE...
6
by: rodchar | last post by:
hey all, i'm trying to use Windows' Task Manager to kick off my win form. Am I correct to say that this is not going to work because everytime it runs I see it task manager but no window ever...
10
by: shiry | last post by:
Hi, I need to do some important cleanup before my console application exists. I used the console ctrl event. This is working well and it fires for all cases, including the CTRL_CLOSE_EVENT (if I...
4
by: Strah | last post by:
Is there a way to catch the event of terminating the application from the the processes tab in task manager? I have created windows app, and if a user termintates the app in the task manager,...
4
by: ray well | last post by:
on my developing system, when my app exits, it always gets removed withing a second from the task manager. on my clients machine, the app exits but stays indefinitely in the task manager. i...
3
by: Inbox.Mirror.Orbisoft | last post by:
In the last 1-3 weeks, we have had numerous users of Task Manager 2007 (www.orbisoft.com) complain that they can no longer export certain reports (Task Manager 2007 uses a Sagekey.com Access 97...
3
by: =?Utf-8?B?U3RldmUgQmFya2Vy?= | last post by:
Hi guys, I know this post isn't strictly related to the forum topic, but it's such a general question that I didn't know where else to post it! Feel free to suggest a more suitable alternative!...
4
by: e-Ricc | last post by:
Hi guys! Im trying to detect when a user "kills" my c# app using windows task manager, i've tried with the form events _closing and _closed managing for example putting an if inside to detect...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.