Bin im Urlaub und kann das nicht testen!
Quelle von hier :
Spoiler anzeigen
$list = ProcessList("SvcHost.exe")
for $i = 1 to $list[0][0]
$pid = $list[$i][1]
Local $hProc = DllCall("kernel32.dll", "int", "OpenProcess", "int", 0x0410, "int", False, "int", $pid)
If $hProc[0] Then
Local $stHMod = DllStructCreate("int hMod")
Local $stCB = DllStructCreate("dword cbNeeded")
Local $resEnum = DllCall("psapi.dll", "int", "EnumProcessModules", "int", $hProc[0], "ptr", DllStructGetPtr($stHMod), "dword", DllStructGetSize($stHMod), "ptr", DllStructGetPtr($stCB, 1))
If $resEnum[0] Then
Local $resPath = DllCall("psapi.dll", "int", "GetModuleFileNameEx", "int", $hProc[0], "int", DllStructGetData($stHMod, 1), "str", "", "dword", 32768)
MsgBox(0, "PID 2 Path", "" & $Pid & " = " & $resPath[3])
EndIf
$stHMod = 0
$stCB = 0
DllCall("kernel32.dll", 'int', 'CloseHandle', 'int', $hProc[0])
EndIf
Next
Grüsse aus Fethiye
UEZ