05-06-2011, 05:23 PM
PHP Code:
Dim notepad() As Process = System.Diagnostics.Process.GetProcessesByName("notepad")
Just wondering if this gets process "NoTePaD" or "Notepad" or only "notepad"? Simple question but I'm confused...
Question about GetProcessByName
|
05-06-2011, 05:23 PM
PHP Code: Dim notepad() As Process = System.Diagnostics.Process.GetProcessesByName("notepad") Just wondering if this gets process "NoTePaD" or "Notepad" or only "notepad"? Simple question but I'm confused...
05-06-2011, 05:44 PM
I'm just guessing now, didn't use C# for a while now.
GetProcessesByName(processName) should get all instances of "notepad", including "Notepad" and "NoTePaD". So processName is as far as I know case-insensitive. On the other hand, the member of Process, Process.ProcessName is case-sensitive.
05-06-2011, 07:09 PM
(05-06-2011, 05:44 PM)Gaijin Wrote: I'm just guessing now, didn't use C# for a while now. Thanks for the info! That was what I thought but doesn't hurt to re-check... |
« Next Oldest | Next Newest »
|