public void unhook() { if (hhook != IntPtr.Zero) { NativeMethods.UnhookWindowsHookEx(hhook); hhook = IntPtr.Zero; } }