Func commandLineGet($proc, $strComputer=".") dim $array[1] local $ArrayNumber local $oWMI = ObjGet("winmgmts:{impersonationLevel=impersonate}!\\" & $strComputer & "\root\cimv2") local $oProcessColl = $oWMI.ExecQuery("Select * from Win32_Process where name= " & '"'& $Proc & '"') local $Process For $Process In $oProcessColl $Process = $Process.Commandline ReDim $Array[UBound($Array)+1] $ArrayNumber = UBound($Array)-1 $array[$ArrayNumber] = $Process Next $ArrayNumber = UBound($Array)-1 $array[0] = $ArrayNumber return $array EndFunc