Results 1 to 3 of 3
Thread: StartingAndKillingProcessesInXP
- 02-07-2009, 07:51 AM #1
Member
- Join Date
- Feb 2009
- Posts
- 2
- Rep Power
- 0
- 02-07-2009, 12:40 PM #2
Senior Member
- Join Date
- Jun 2008
- Posts
- 339
- Rep Power
- 5
You can't do this directly from Java. You could perhaps run an external program from Java and examine its output, using Runtime.exec(..), or you could use the JNI (Java Native Interface) to create a DLL to hook you up to the Windows OS process APIs, but it's a lot of work.
For this kind of task, you're better finding an appropriate tool for the job, i.e. a native language such as C/C++ or C#.
- 02-07-2009, 06:59 PM #3
Senior Member
- Join Date
- Jan 2009
- Posts
- 671
- Rep Power
- 5
To write a java program that allows you to launch processes, kill processes it launched, and view processes it launched is straightforward using Runtime.exec, but it would not be a general process manager that could kill/view arbitrary processes. As dlorde suggested, a native language that hooks directly into the windows API is needed for general process management.


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks