术语 | getprocessid |
释义 | GetProcessId 语法: C++ DWORD WINAPI GetProcessId( __in HANDLE Process ); GetProcessId功能 检索指定的进程的进程标识符。 参数 工艺 [in] 句柄的进程。句柄必须有PROCESS_QUERY_INFORMATION或PROCESS_QUERY_LIMITED_INFORMATION访问权限。有关更多信息,请参见过程的安全性和访问权限。 Windows Server 2003和Windows XP中:在处理必须有PROCESS_QUERY_INFORMATION访问权。 返回值 如果函数成功,返回值是指定的进程的进程标识符。 如果函数失败,返回值是零。为了获得更多错误信息,调用GetLastError。 备注 Until a process terminates, its process identifier uniquely identifies it on the system.如需有关访问权限的信息,请参见过程的安全性和访问权限。 要求: 最低支持clientWindows SP1的Vista中,Windows XP的 最低支持serverWindows服务器2003 HeaderWinbase.h(头文件:winuser.h) LibraryKernel32.lib DLLKernel32.dll 参见 GetCurrentProcessId GetProcessIdOfThread GetThreadId 过程 如果有任何问题和意见,请发送给微软(wsddocfb@microsoft.com) 生成日期:2009年8月27日 ==英文原文==GetProcessId Function Retrieves the process identifier of the specified process. Syntax C++ DWORD WINAPI GetProcessId( __in HANDLE Process ); Parameters Process [in] A handle to the process. The handle must have the PROCESS_QUERY_INFORMATION or PROCESS_QUERY_LIMITED_INFORMATION access right. For more information, see Process Security and Access Rights . Windows Server 2003 and Windows XP: The handle must have the PROCESS_QUERY_INFORMATION access right. Return Value If the function succeeds, the return value is the process identifier of the specified process. If the function fails, the return value is zero. To get extended error information, call GetLastError . Remarks Until a process terminates, its process identifier uniquely identifies it on the system. For more information about access rights, see Process Security and Access Rights. Requirements Minimum supported clientWindows Vista, Windows XP with SP1 Minimum supported serverWindows Server 2003 HeaderWinbase.h (include Windows.h) LibraryKernel32.lib DLLKernel32.dll See Also GetCurrentProcessId GetProcessIdOfThread GetThreadId Processes Send comments about this topic to Microsoft Build date: 8/27/2009 ==原始网址==http://msdn.microsoft.com/en-us/library/ms683215(VS.85).aspx\n |
随便看 |
|
windows api函数参考手册包含2258条windows api函数文档,详细介绍nodejs、java、rust调用windows api的方法技巧,是学习windows api编程的入门中文文档。