C# GetWindowThreadProcessId用法
变量a的值是句柄,怎样得到PID?(让pid被赋为b的值) --------------------编程问答--------------------
//获取与指定窗口关联在一起的一个进程和线程标识符
[DllImport("user32", EntryPoint = "GetWindowThreadProcessId")]
private static extern int GetWindowThreadProcessId(int hwnd,
out int lpdwProcessId);
int b; //进程标识
GetWindowThreadProcessId(a, out b);
补充:.NET技术 , C#