|
珞珈山水BBS →
电脑网络 →
程序人生 →
单文区文章阅读
|
| 单文区文章阅读 [返回] |
|---|
|
发信人: Stravadivaly (老子就是机器人), 信区: Programm 标 题: Re: 枚举系统进程问题 发信站: BBS 珞珈山水站 (Sun May 28 15:25:19 2006) 郁闷了: #include <Windows.h> #include <stdio.h> #include <Winternl.h> #include <Winbase.h> #pragma comment(lib, "Kernel32.lib") int main(void) { //枚举系统进程 HINSTANCE hinstLib; hinstLib = LoadLibrary("Ntdll"); SYSTEM_PROCESS_INFORMATION SystemProcessInformation; NtQuerySystemInformation(SYSTEM_PROCESS_INFORMATION, &SystemProcessInformation, sizeof(SystemProcessInformation), NULL); FreeLibrary(hinstLib); return 0; } e:\acm\findfile\find2.cpp(19) : error C2065: 'SYSTEM_PROCESS_INFORMATION' : un declared identifier e:\acm\findfile\find2.cpp(19) : error C2146: syntax error : missing ';' before identifier 'SystemProcessInformation' e:\acm\findfile\find2.cpp(19) : error C2065: 'SystemProcessInformation' : unde clared identifier e:\acm\findfile\find2.cpp(21) : error C2065: 'NtQuerySystemInformation' : unde clared identifier 到MSDN 上查了查,第一句话就是: [NtQuerySystemInformation may be altered or unavailable in future versions of Windows. Applications should use the alternate functions listed in this topic. ] 而且在MSDN上查不到 SYSTEM_PROCESS_INFORMATION 的帮助。 是哪里错了? -- 是吗? 不是吗? 对吗? 不对吗? 傻吗? ...... 的确很傻. 就像" 树动风欲静, 日涌大山流". ※ 来源:·珞珈山水BBS站 http://bbs.whu.edu.cn·[FROM: 221.232.28.*] |
| [返回单文区目录] |
|
|