Using WMI I can get the full path of a process on a remote computer:
"SELECT ExecutablePath FROM Win32_Process"
Without wmi I can get theprocessname and id:
For Each ps In System.Diagnostics.Process.GetProcesses(PC.Name)
processgrid.Rows.Add(ps.ProcessName, ps.Id)
Next ps
Any ideas how I can get the process path (using vb 2005)
Thanks,
Pete. 7 4359
xla76 wrote:
Using WMI I can get the full path of a process on a remote computer:
"SELECT ExecutablePath FROM Win32_Process"
Without wmi I can get theprocessname and id:
For Each ps In System.Diagnostics.Process.GetProcesses(PC.Name)
processgrid.Rows.Add(ps.ProcessName, ps.Id)
Next ps
Any ideas how I can get the process path (using vb 2005)
Thanks,
Pete.
I think ps.StartInfo.FileName returns the full path.
HTH,
RB.
On Sep 19, 12:03 pm, RB <owmdkbqziki...@mailinator.comwrote:
xla76 wrote:
Using WMI I can get the full path of a process on a remote computer:
"SELECT ExecutablePath FROM Win32_Process"
Without wmi I can get theprocessname and id:
For Each ps In System.Diagnostics.Process.GetProcesses(PC.Name)
processgrid.Rows.Add(ps.ProcessName, ps.Id)
Next ps
Any ideas how I can get the process path (using vb 2005)
Thanks,
Pete.
I think ps.StartInfo.FileName returns the full path.
HTH,
RB.
I tried that, but it only returned a bunch of zero length strings.
xla76 wrote:
On Sep 19, 12:03 pm, RB <owmdkbqziki...@mailinator.comwrote:
>xla76 wrote:
>>Using WMI I can get the full path of a process on a remote computer: "SELECT ExecutablePath FROM Win32_Process" Without wmi I can get theprocessname and id: For Each ps In System.Diagnostics.Process.GetProcesses(PC.Name) processgrid.Rows.Add(ps.ProcessName, ps.Id) Next ps Any ideas how I can get the process path (using vb 2005) Thanks, Pete.
I think ps.StartInfo.FileName returns the full path.
HTH,
RB.
I tried that, but it only returned a bunch of zero length strings.
Okey dokey,
Have you tried ps.MainModule.FileName?
( http://msdn2.microsoft.com/en-us/lib...e_members.aspx)
Cheers,
RB.
On 19 Sep, 14:34, RB <owmdkbqziki...@mailinator.comwrote:
xla76 wrote:
On Sep 19, 12:03 pm, RB <owmdkbqziki...@mailinator.comwrote:
xla76 wrote: Using WMI I can get the full path of a process on a remote computer: "SELECT ExecutablePath FROM Win32_Process" Without wmi I can get theprocessname and id: For Each ps In System.Diagnostics.Process.GetProcesses(PC.Name) processgrid.Rows.Add(ps.ProcessName, ps.Id) Next ps Any ideas how I can get the process path (using vb 2005) Thanks, Pete.
I think ps.StartInfo.FileName returns the full path.
HTH,
RB.
I tried that, but it only returned a bunch of zero length strings.
Okey dokey,
Have you tried ps.MainModule.FileName?
(http://msdn2.microsoft.com/en-us/lib...tics.processmo...)
Cheers,
RB.
I Tried it but got: feature is not supported for remote machines!
On Sep 19, 4:12 pm, xla76 <xla...@gmail.comwrote:
On 19 Sep, 14:34, RB <owmdkbqziki...@mailinator.comwrote:
xla76 wrote:
On Sep 19, 12:03 pm, RB <owmdkbqziki...@mailinator.comwrote:
>xla76 wrote:
>>Using WMI I can get the full path of a process on a remote computer:
>> "SELECT ExecutablePath FROM Win32_Process"
>>Without wmi I can get theprocessname and id:
>> For Each ps In System.Diagnostics.Process.GetProcesses(PC.Name)
>> processgrid.Rows.Add(ps.ProcessName, ps.Id)
>> Next ps
>>Any ideas how I can get the process path (using vb 2005)
>>Thanks,
>>Pete.
>I think ps.StartInfo.FileName returns the full path.
>HTH,
>RB.
I tried that, but it only returned a bunch of zero length strings.
Okey dokey,
Have you tried ps.MainModule.FileName?
(http://msdn2.microsoft.com/en-us/lib...tics.processmo...)
Cheers,
RB.
I Tried it but got: feature is not supported for remote machines!
So, back to WMI then?
xla76 wrote:
On Sep 19, 4:12 pm, xla76 <xla...@gmail.comwrote:
>On 19 Sep, 14:34, RB <owmdkbqziki...@mailinator.comwrote:
>>xla76 wrote: On Sep 19, 12:03 pm, RB <owmdkbqziki...@mailinator.comwrote: xla76 wrote: >Using WMI I can get the full path of a process on a remote computer: > "SELECT ExecutablePath FROM Win32_Process" >Without wmi I can get theprocessname and id: > For Each ps In System.Diagnostics.Process.GetProcesses(PC.Name) > processgrid.Rows.Add(ps.ProcessName, ps.Id) > Next ps >Any ideas how I can get the process path (using vb 2005) >Thanks, >Pete. I think ps.StartInfo.FileName returns the full path. HTH, RB. I tried that, but it only returned a bunch of zero length strings. Okey dokey, Have you tried ps.MainModule.FileName? (http://msdn2.microsoft.com/en-us/lib...tics.processmo...) Cheers, RB.
I Tried it but got: feature is not supported for remote machines!
So, back to WMI then?
The only other suggestion I can think of is to create a service on the
remote machine that would report back the list of processes running on
the remote machine.
Actually, that would be quite cool - you could make it a web-service and
then query it from any computer through a web-based interface as well as
from your application :-) Um - don't know if that's what you want though!!
Cheers,
RB.
On Sep 21, 10:48 am, RB <owmdkbqziki...@mailinator.comwrote:
xla76 wrote:
On Sep 19, 4:12 pm, xla76 <xla...@gmail.comwrote:
On 19 Sep, 14:34, RB <owmdkbqziki...@mailinator.comwrote:
>xla76 wrote: On Sep 19, 12:03 pm, RB <owmdkbqziki...@mailinator.comwrote: xla76 wrote: Using WMI I can get the full path of a process on a remote computer: "SELECT ExecutablePath FROM Win32_Process" Without wmi I can get theprocessname and id: For Each ps In System.Diagnostics.Process.GetProcesses(PC.Name) processgrid.Rows.Add(ps.ProcessName, ps.Id) Next ps Any ideas how I can get the process path (using vb 2005) Thanks, Pete. I think ps.StartInfo.FileName returns the full path. HTH, RB. I tried that, but it only returned a bunch of zero length strings. Okey dokey, Have you tried ps.MainModule.FileName? (http://msdn2.microsoft.com/en-us/lib...tics.processmo...) Cheers, RB.
I Tried it but got: feature is not supported for remote machines!
So, back to WMI then?
The only other suggestion I can think of is to create a service on the
remote machine that would report back the list of processes running on
the remote machine.
Actually, that would be quite cool - you could make it a web-service and
then query it from any computer through a web-based interface as well as
from your application :-) Um - don't know if that's what you want though!!
Cheers,
RB.
Thanks for your efforts RB, but I just wanted a method of reading/
controlling processes as and when required, so a service would be
overkill (and over my head at the minute - though I will look into it
at some stage).
Regards
Pete This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Nick Bunton |
last post by:
I have setup remote debugging on an NT4 workstation for
testing. I then build from the debug config on my machine
and copy all the files from the /bin/debug folder
including the .PDB files. I then...
|
by: Céline |
last post by:
HI everybody,
I am trying to get somewhere with VisualStudio.net. The problem is
that my web server is not on my PC (for company security reason) on is
remote.
Everytime I try to create a...
|
by: Chidvilas |
last post by:
// Get all processes running on the remote computer.
Process remoteAll = Process.GetProcesses("XYZ");
when I am exectuing the above code, it is giving excetpion saying "Couldn't
get process...
|
by: Jeremy |
last post by:
Hello,
I am trying to determine some information about a process on a remote
machine using the following code.
Dim ps As System.Diagnostics.Process
For Each ps In...
|
by: XxLicherxX |
last post by:
Hello everyone,
I a program that pulls the processes off of remote machines using the
Process.GetProcesses() function. What I want to be able to do is get
some information about the process,...
|
by: Ken Allen |
last post by:
The MSDN documentation on remote debugging is a bit sparse, to say the
least, and there is almost no information available on the 'best' way to
configure this. I should note that my development...
|
by: Manu |
last post by:
Hi,
How to get the USERNMAE of all the process which are running on local
/remote system. I have go through the "System.Diagnostics.Process class" but
I couldn't find any useful information....
|
by: Bob Altman |
last post by:
Hi all,
This is a long shot, but I figure it doesn't hurt to ask... I have some
applications that work fine when I run them on my PC at work, but "fail to
initialize (0x000005)" when I'm...
|
by: srinivasan srinivas |
last post by:
HI,
I am using Solaris and subprocess.Popen to spawn a process on a remote machine.
Thanks,
Srini
----- Original Message ----
From:Diez B. Roggisch <deets@nospam.web.de>
To:...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: Vimpel783 |
last post by:
Hello!
Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
|
by: ArrayDB |
last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
|
by: PapaRatzi |
last post by:
Hello,
I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: Defcon1945 |
last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
| |