Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Java.exe PID

Reply
Thread Tools

Java.exe PID

 
 
randy
Guest
Posts: n/a
 
      05-11-2004
How do i get PID of the current java.exe. ON windows

public class PIDTest
{
public static void main(String[] args)
{
String PID = ???
System.out.println(" ProcessID = "+PID);
System.getProperties().list(System.out);
}
}
Thanks for any help you can give,
randy


 
Reply With Quote
 
 
 
 
Roedy Green
Guest
Posts: n/a
 
      05-11-2004
On Tue, 11 May 2004 16:27:37 -0400, "randy" <(E-Mail Removed)>
wrote or quoted :

>How do i get PID of the current java.exe. ON windows


PID is not a platform independent concept. Use JNI or exec something
and capture the output.

see http://mindprod.com/jgloss/jni.html
http://mindprod.com/jgloss/exec.html

check if Jconfig supports it.

see http://mindprod.com/jgloss/jconfig.html

--
Canadian Mind Products, Roedy Green.
Coaching, problem solving, economical contract programming.
See http://mindprod.com/jgloss/jgloss.html for The Java Glossary.
 
Reply With Quote
 
 
 
 
Real Gagnon
Guest
Posts: n/a
 
      05-11-2004
> How do i get PID of the current java.exe. ON windows

You can find a JNI DLL at
http://www.rgagnon.com/javadetails/java-0467.html

Bye.
--
Real Gagnon from Quebec, Canada
* Looking for Java or PB snippets ? Visit Real's How-to
* http://www.rgagnon.com/howto.html
 
Reply With Quote
 
 
 
Reply

Thread Tools

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Embedded perl - how to find out real PID after fork Andrew Zhilenko Perl 0 11-22-2004 07:11 AM
Catch pid for a process that created Mav Perl 2 08-20-2004 08:56 PM
Process PID Sigal Perl 1 02-18-2004 03:20 PM
kill(0,$pid) return 1 after application is killed manually dkryzman@hotmail.com Perl 0 11-05-2003 10:16 PM
PID NUMBER ROCKS Microsoft Certification 1 10-13-2003 04:05 AM



Advertisments