Process Filename
-
how do i get the filename of a process?I know how to get the list of processes on a local machine, but i'd like to know how to get the full path (i.e: c:\windows\system32\svchost.exe) of a process.
you can use the
Process.GetProcessesByName
orProcess.GetProcesses
to get aProcess
object. You can then use theMainModule
property to get aProcessModule
object for the process, and the ProcessModule has aFileName
property that gives a full path to the processes .exe (etc.)1001111111011101111100111100101011110011110100101110010011010010
Sonork | 100.21142 | TheEclypse -
you can use the
Process.GetProcessesByName
orProcess.GetProcesses
to get aProcess
object. You can then use theMainModule
property to get aProcessModule
object for the process, and the ProcessModule has aFileName
property that gives a full path to the processes .exe (etc.)1001111111011101111100111100101011110011110100101110010011010010
Sonork | 100.21142 | TheEclypse -
no problem. :)
1001111111011101111100111100101011110011110100101110010011010010
Sonork | 100.21142 | TheEclypse