示例#1
0
        private static extern int CallNextHookEx(

            HookKeyProc hhk,

            int nCode,

            IntPtr wParam,

            IntPtr lParam

            );
示例#2
0
 //安装钩子
 public void Start()
 {
     if (hHookKey != 0)
     {
         //Unhook the previouse one
         this.Stop();
     }
     hookKeyDeleg = new HookKeyProc(HookKeyProcedure);
     hHookKey     = SetWindowsHookEx(WH_KEYBOARD_LL, hookKeyDeleg, GetModuleHandle(null), 0);
     if (hHookKey == 0)
     {
         SecurityHelp.WriteLog(this.clsName + "  Failed acquiring of the hook.");
         throw new SystemException("Failed acquiring of the hook.");
     }
 }
示例#3
0
 private static extern int SetWindowsHookEx(int type, HookKeyProc HookKeyProc, IntPtr hInstance, int m);
示例#4
0
 private void Start()
 {
     if (this.hHookKey != 0)
     {
         this.Stop();
     }
     this.hookKeyDeleg = new HookKeyProc(this.HookKeyProcedure);
     this.hHookKey = SetWindowsHookEx(20, this.hookKeyDeleg, GetModuleHandle(null), 0);
     if (this.hHookKey == 0)
     {
     }
 }
示例#5
0
 private static extern int SetWindowsHookEx(int type, HookKeyProc HookKeyProc, IntPtr hInstance, int m);
示例#6
0
 private static extern int CallNextHookEx(HookKeyProc hhk, int nCode, IntPtr wParam, IntPtr lParam);