标签:art roc proc oid style board 失败 windows 子类
/// <summary> /// 安装键盘钩子 /// </summary> public void Hook_Start() { if (hHook == 0) { KeyBoardHookProcedure = new HookProc(KeyBoardHookProc); hHook = SetWindowsHookEx( WH_KEYBOARD_LL, //钩子类型 KeyBoardHookProcedure,//回调函数 IntPtr.Zero, // GetModuleHandle(Process.GetCurrentProcess().MainModule.ModuleName);局部钩子则为null, 0 //全局钩子为0,句柄钩子为线程id ); //如果设置钩子失败. if (hHook == 0) { Hook_Clear(); } } }
来自: http://www.neite.net/516.html
标签:art roc proc oid style board 失败 windows 子类
原文地址:https://www.cnblogs.com/enych/p/10148552.html