Python Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPython Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Generate data entry and reporting .NET Web apps in minutes, straight from your database. Read our FREE whitepaper “Build Web 2.0 Applications Without Hand-Coding” Download now!
  #1  
Old March 28th, 2004, 12:27 AM
lentyaka lentyaka is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2004
Posts: 6 lentyaka User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
killing a running process

I am wondering if someone knows how to kill a process after the application was closed. I have an application written in python but when I close the window, the process is still running in Task Manager. So I have to go and 'end process' manually each time through task manager.
Maybe someone knows how to tell OS to destroy the process after the app was closed??
Thank you.

Regards,
lentyaka

Reply With Quote
  #2  
Old March 28th, 2004, 02:42 AM
Grim Archon's Avatar
Grim Archon Grim Archon is offline
Mini me.
Dev Shed Novice (500 - 999 posts)
 
Join Date: Nov 2003
Location: Cambridge, UK
Posts: 783 Grim Archon User rank is Corporal (100 - 500 Reputation Level)Grim Archon User rank is Corporal (100 - 500 Reputation Level)Grim Archon User rank is Corporal (100 - 500 Reputation Level)Grim Archon User rank is Corporal (100 - 500 Reputation Level)  Folding Points: 1488 Folding Title: Novice Folder
Time spent in forums: 3 Days 2 h 15 m 57 sec
Reputation Power: 7
Send a message via MSN to Grim Archon
Hi lentyaka,

Not really answering your question but if the process is still there after you "terminate" the program then you did not terminate the program. The OS can't guess.

When this happens in my code I use a [b]try .... finally[b/] block in the main module. So whatever happens to my code the finally section is always run. This is very useful for manually closing Win32 resources that are still open after an exception.

In Tkinter it's a common error (for me ) to call the destroy() method when I really ment to call the quit() method - this can leave the process running but the actual window graphics are no longer visible.

Grim
__________________
*** Experimental Python Markup CGI V2 ***

Reply With Quote
  #3  
Old March 30th, 2004, 05:23 PM
lentyaka lentyaka is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2004
Posts: 6 lentyaka User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
thanx a lot, it helped

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPython Programming > killing a running process


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway