Getting info on currently executing programs 
Author Message
 Getting info on currently executing programs

I want to write a small task switching utility which will sit on my desktop
and show all the programs/windows I currently have running/open so that I
can switch between them with a mouse click.

Is there a class in the .net framework which provides information on the
programs currently running or on the windows currently open?

I have been through the .net documentation & the Professional C# wrox book
to no avail.

Many thanks,

Mike



Mon, 28 Mar 2005 20:04:30 GMT  
 Getting info on currently executing programs
Mike,

    You can always call the static GetProcesses method on the Process class.
Once you have this, you can get the handle for the window on each process
and then call ShowWindow through the P/Invoke layer.

    Hope this helps.

--
               - Nicholas Paldino [.NET/C# MVP]


Quote:
> I want to write a small task switching utility which will sit on my
desktop
> and show all the programs/windows I currently have running/open so that I
> can switch between them with a mouse click.

> Is there a class in the .net framework which provides information on the
> programs currently running or on the windows currently open?

> I have been through the .net documentation & the Professional C# wrox book
> to no avail.

> Many thanks,

> Mike



Mon, 28 Mar 2005 21:21:09 GMT  
 Getting info on currently executing programs
Here is a little C# app. showing how to enumerate all current windows,
and get some basic info. back. Easy to extend:
  http://home.istar.ca/~neutron/enumwindows/EnumWins.cs

 - Michel Gallant   MVP Security
    http://home.istar.ca/~neutron



Quote:
> Mike,

>     You can always call the static GetProcesses method on the Process class.
> Once you have this, you can get the handle for the window on each process
> and then call ShowWindow through the P/Invoke layer.

>     Hope this helps.

> --
>                - Nicholas Paldino [.NET/C# MVP]



> > I want to write a small task switching utility which will sit on my
> desktop
> > and show all the programs/windows I currently have running/open so that I
> > can switch between them with a mouse click.

> > Is there a class in the .net framework which provides information on the
> > programs currently running or on the windows currently open?

> > I have been through the .net documentation & the Professional C# wrox book
> > to no avail.

> > Many thanks,

> > Mike



Mon, 28 Mar 2005 22:55:12 GMT  
 Getting info on currently executing programs


Wed, 18 Jun 1902 08:00:00 GMT  
 Getting info on currently executing programs
Thanks in advance to anyone who can help me.

I'm tinkering with .net and part of the program that I am designing requires
the ability to detect how long someone has been idle (i.e. no keystrokes
detected) and then display a prompt if someone exceeds that pre-determined
amount of time.

Can someone point me to an article, or give off some keywords that might
help me to find information on how to do this?

Thanks!
Chris



Wed, 30 Mar 2005 03:01:55 GMT  
 Getting info on currently executing programs
Ug, I hit reply instead of post and buried my post under someone else's
post.  Sorry for this repost; just wanted to make sure someone found it.

Thanks in advance to anyone who can help me.

I'm tinkering with .net and part of the program that I am designing requires
the ability to detect how long someone has been idle (i.e. no keystrokes
detected) and then display a prompt if someone exceeds that pre-determined
amount of time.

Can someone point me to an article, or give off some keywords that might
help me to find information on how to do this?

Thanks!
Chris



Wed, 30 Mar 2005 04:25:12 GMT  
 Getting info on currently executing programs
Chris, to do this across the system as a whole you will have to resort to
unmanaged C++.  You can set a system hook using the SetSystemHook API.
Check out this post (watch line wrap).  If you have any specific questions
feel free to post.

http://groups.google.com/groups?q=C%23+greg+Ewing+SetSystemHook&hl=en...
=UTF-8&oe=UTF-8&selm=330f01c1fc16%24c2157230%242ae2c90a%40hosting.microsoft.
com&rnum=1

--
Greg Ewing [MVP]
http://www.claritycon.com/


Quote:
> Ug, I hit reply instead of post and buried my post under someone else's
> post.  Sorry for this repost; just wanted to make sure someone found it.

> Thanks in advance to anyone who can help me.

> I'm tinkering with .net and part of the program that I am designing
requires
> the ability to detect how long someone has been idle (i.e. no keystrokes
> detected) and then display a prompt if someone exceeds that pre-determined
> amount of time.

> Can someone point me to an article, or give off some keywords that might
> help me to find information on how to do this?

> Thanks!
> Chris



Thu, 31 Mar 2005 03:48:45 GMT  
 Getting info on currently executing programs
Thanks for the reply!  I'll look into.



Quote:
> Chris, to do this across the system as a whole you will have to resort to
> unmanaged C++.  You can set a system hook using the SetSystemHook API.
> Check out this post (watch line wrap).  If you have any specific questions
> feel free to post.

http://groups.google.com/groups?q=C%23+greg+Ewing+SetSystemHook&hl=en...
=UTF-8&oe=UTF-8&selm=330f01c1fc16%24c2157230%242ae2c90a%40hosting.microsoft.
Quote:
> com&rnum=1

> --
> Greg Ewing [MVP]
> http://www.claritycon.com/



> > Ug, I hit reply instead of post and buried my post under someone else's
> > post.  Sorry for this repost; just wanted to make sure someone found it.

> > Thanks in advance to anyone who can help me.

> > I'm tinkering with .net and part of the program that I am designing
> requires
> > the ability to detect how long someone has been idle (i.e. no keystrokes
> > detected) and then display a prompt if someone exceeds that
pre-determined
> > amount of time.

> > Can someone point me to an article, or give off some keywords that might
> > help me to find information on how to do this?

> > Thanks!
> > Chris



Thu, 31 Mar 2005 12:48:51 GMT  
 Getting info on currently executing programs


Wed, 18 Jun 1902 08:00:00 GMT  
 Getting info on currently executing programs
Mike,

I happened to be browsing the on-line August 2002 MSDN magazine tonight and
came across :

http://msdn.microsoft.com/msdnmag/issues/02/08/CQA/default.aspx

which has downloadable C# source for enumerating windows/processes. And he
has packaged
it in a very modular way.

best, Bill


Quote:
> I want to write a small task switching utility which will sit on my
desktop
> and show all the programs/windows I currently have running/open so that I
> can switch between them with a mouse click.

> Is there a class in the .net framework which provides information on the
> programs currently running or on the windows currently open?

> I have been through the .net documentation & the Professional C# wrox book
> to no avail.

> Many thanks,

> Mike



Thu, 05 May 2005 06:10:26 GMT  
 
 [ 10 post ] 

 Relevant Pages 

1. Getting the list of programs currently running

2. Retrieving properties of currently executing method

3. Name of currently executing method?

4. Getting currently logged user (Novell)

5. Getting currently active document

6. HELP : EXECUTE a .exe program within a c or c++ program

7. Thread executing, info during debugging?

8. Executing a program in a program

9. IF i execute that program, that Program Disappears(maybe end)

10. execute program to dll program

11. Executing program within an other program

12. : when execute a program in other program by function

 

 
Powered by phpBB® Forum Software