473,698 Members | 2,635 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Finding out what other tasks are running

Is there a cross-platform of determining what other processes (or in Windows
terms, other applications) are running?

Is it possible in a cross-platform way to ask some other application to shut
down, wait a while, and then test to see if it did shut?

Failing that are there separate Windows, Mac and Linux/Unix ways of doing
this?

--
Jeremy C B Nicoll - my opinions are my own.
Nov 23 '07 #1
3 1583
Jeremy C B Nicoll wrote:
Is there a cross-platform of determining what other processes (or in Windows
terms, other applications) are running?

Is it possible in a cross-platform way to ask some other application to shut
down, wait a while, and then test to see if it did shut?

Failing that are there separate Windows, Mac and Linux/Unix ways of doing
this?
Sorry, thought I'd part-answered this a while back; doesn't seem
to have shown up. In short, I don't believe there's anything
truly x-platform. On Windows, one approach is WMI. Here's an
example:

http://tgolden.sc.sabren.com/python/...ning_processes

There are other techniques, such as querying the top-level
windows or using the performance objects from the pywin32
modules.

TJG
Nov 23 '07 #2
Jeremy C B Nicoll wrote:
Is there a cross-platform of determining what other processes (or in
Windows
terms, other applications) are running?

Is it possible in a cross-platform way to ask some other application
to shut
down, wait a while, and then test to see if it did shut?

Failing that are there separate Windows, Mac and Linux/Unix ways of doing
this?
Ah. Just realised: you're the chap who asked on the PyUK list.
Didn't really give a detailed answer there, did I? Sorry. For
*nix, have a look at Chris Miles' PSI. (Another Londoner like me).

http://www.psychofx.com/psi/trac/wiki/

TJG

Nov 23 '07 #3
Tim Golden wrote:
Jeremy C B Nicoll wrote:
>Is there a cross-platform of determining what other processes (or in Windows
terms, other applications) are running?

Is it possible in a cross-platform way to ask some other application to shut
down, wait a while, and then test to see if it did shut?

Failing that are there separate Windows, Mac and Linux/Unix ways of doing
this?

Sorry, thought I'd part-answered this a while back; doesn't seem
to have shown up. In short, I don't believe there's anything
truly x-platform...
.... or I could eat my words and point you towards Christian Heimes
enumprocess package:

http://cheeseshop.python.org/pypi/enumprocess

TJG
Nov 23 '07 #4

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

Similar topics

3
8590
by: Greg Bryant | last post by:
I'm doing some work for a company that has an auction site running in coldfusion. They're not real happy with it, and it needs a major overhaul, so I'm looking at redoing it, and while I'm at it, might as well move to PHP (for a variety of reasons - not trying to reopen the PHP -vs- CFM thing again :). Anyway, so I'm looking at this system, and there are no "scheduled tasks" (it's win2kas). How do you write a server app that needs to...
220
19038
by: Brandon J. Van Every | last post by:
What's better about Ruby than Python? I'm sure there's something. What is it? This is not a troll. I'm language shopping and I want people's answers. I don't know beans about Ruby or have any preconceived ideas about it. I have noticed, however, that every programmer I talk to who's aware of Python is also talking about Ruby. So it seems that Ruby has the potential to compete with and displace Python. I'm curious on what basis it...
11
4077
by: Codemonkey | last post by:
Hi, I am writing an App in .Net that involves some scheduling of tasks. I was wondering if anybody has come accross any components or examples of how to implement a schedule manager like the one in the Task Scheduler for Windows? Basically I'm after something that'll allow me to specify a "recurring" or "once off" schedule with advanced options like "the first monday in the month" etc.
3
1854
by: Tim | last post by:
Hello Everyone I'd like to create a script/program that can locate all servers running DB2, finding out which instances are running/created and what databases are running under them but have been told but IBM support that this isn't currently possible for a client to do. I'd like to get a second opinion since the CCA seems to be able to manage it without any problems so the API must be there to do it. The main reason why I'd like...
2
1599
by: Bjarne | last post by:
Dear all, although being a user of PHP and other scripting-languages for years, I have not taken part in any large projects based on PHP. Thus, I don't really know how real PHP-applications are deployed out there. This posting is a request for input from professional PHP-users and architects with experience from designing PHP applications. My company makes a toolkit for developing WebServices. This toolkit is typically used to expose an...
1
7537
by: me | last post by:
Hi, Im having a few issues with finding exactly which program may be accessing a certain file. Lets say I need to replace a DLL with a newer version, but I need to make sure its not being accessed. Finding out if its in use isnt a problem, but I need to find out exactly which process is using it so I can ask the user if they would like to end that process to replace the file or not.
3
3440
by: kj7ny | last post by:
How can I access and manipulate Scheduled Tasks in Windows using Python? I have a Windows XP workstation running Python 2.4.4 using the win32all modules to control the windows services on multiple Windows 2003 servers. It works great. However, I also need to remotely collect the settings for the scheduled tasks (on those same Windows 2003 servers) and then manipulate those task settings.
167
8293
by: darren | last post by:
Hi I have to write a multi-threaded program. I decided to take an OO approach to it. I had the idea to wrap up all of the thread functions in a mix-in class called Threadable. Then when an object should run in its own thread, it should implement this mix-in class. Does this sound like plausible design decision? I'm surprised that C++ doesn't have such functionality, say in its STL. This absence of a thread/object relationship in...
0
1351
by: BD | last post by:
I'm running 8.2 on Windows. I have a situation where several scheduled tasks were created in Task Center, under an ID of a person who is leaving the organization. This person's ID is to be deleted, but I see no way of reassigning the owner of these tasks. And I can't change permissions on the tasks without logging in as that 'owner' ID. Is renaming the ID and resetting the password a viable option here?
0
8683
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8610
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9170
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9031
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8873
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7740
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4623
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3052
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2339
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.