c# Programming Glossary: win32_process
How to execute process on remote machine, in c# http://stackoverflow.com/questions/2343677/how-to-execute-process-on-remote-machine-in-c-sharp theClass new ManagementClass @ server root cimv2 Win32_Process theClass.InvokeMethod Create theProcessToRun share improve..
How can I get the PID of the parent process of my application http://stackoverflow.com/questions/2531837/how-can-i-get-the-pid-of-the-parent-process-of-my-application question WMI is the easier way to do this in C#. The Win32_Process class has the ParentProcessId property. Here's an example using.. .Id var query string.Format SELECT ParentProcessId FROM Win32_Process WHERE ProcessId 0 myId var search new ManagementObjectSearcher..
Can I get command line arguments of other processes from .NET/C#? http://stackoverflow.com/questions/2633628/can-i-get-command-line-arguments-of-other-processes-from-net-c new ManagementObjectSearcher SELECT CommandLine FROM Win32_Process WHERE ProcessId p.Id foreach ManagementObject @object in searcher.Get..
How to execute a command in a remote computer? http://stackoverflow.com/questions/428276/how-to-execute-a-command-in-a-remote-computer wmiProcess new ManagementClass wmiScope new ManagementPath Win32_Process new ObjectGetOptions wmiProcess.InvokeMethod Create processToRun..
How to read command line arguments of another process in C#? http://stackoverflow.com/questions/504208/how-to-read-command-line-arguments-of-another-process-in-c one string wmiQuery string.Format select CommandLine from Win32_Process where Name ' 0 ' processName ManagementObjectSearcher searcher..
User logged into remote machine http://stackoverflow.com/questions/5067240/user-logged-into-remote-machine return ObjectQuery query new ObjectQuery select from Win32_Process where name 'explorer.exe' ManagementObjectSearcher searcher..
Logoff interactive users in Windows from a service http://stackoverflow.com/questions/5207506/logoff-interactive-users-in-windows-from-a-service new List string ManagementClass mc new ManagementClass Win32_Process ManagementObjectCollection moc mc.GetInstances foreach ManagementObject..
Kill process tree programatically in C# http://stackoverflow.com/questions/5901679/kill-process-tree-programatically-in-c-sharp searcher new ManagementObjectSearcher Select From Win32_Process Where ParentProcessID pid ManagementObjectCollection moc searcher.Get..
How do I determine the owner of a process in C#? http://stackoverflow.com/questions/777548/how-do-i-determine-the-owner-of-a-process-in-c GetProcessOwner int processId string query Select From Win32_Process Where ProcessID processId ManagementObjectSearcher searcher.. string processName string query Select from Win32_Process Where Name processName ManagementObjectSearcher searcher new..
|