aspose file tools*
The moose likes Other JSE/JEE APIs and the fly likes How to get HUAWEI NetSetter process ID ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "How to get HUAWEI NetSetter process ID ?" Watch "How to get HUAWEI NetSetter process ID ?" New topic
Author

How to get HUAWEI NetSetter process ID ?

Ganesh Pat
Ranch Hand

Joined: Feb 04, 2012
Posts: 79

Hii friends, I've connected Huawei Idea NetSetter to my laptop for internet connection. I want to get process id of this Huwaei Net Setter which is available in
Windows Task Manager -> processes tab in that we have to see Idea Net Setter in Image Name Column and next to that we have PID where i can get this process PID no but i want to get this by java code so please can someone tell me how to do that . Actually i need that PID in SMS sending code so possible please help
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19692
    
  20

You have two options:
1) Use JNI.
2) Use an external application in combination with ProcessBuilder. There are two commands you can use:
- tasklist.exe
- wmic.exe

The latter is a bit trickier but also more powerful. You can find quite a bit of documentation about it.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
Ganesh Pat
Ranch Hand

Joined: Feb 04, 2012
Posts: 79

@ Rob Thank you for help
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19692
    
  20

You're welcome.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to get HUAWEI NetSetter process ID ?