SetWindowsHookEx function fails in VISTA
-
I am testing one application in vista platform and found that SetWindowsHookEx function fails in VISTA. SetWindowsHookEx return NULL.
journalHook = SetWindowsHookEx(WH_JOURNALPLAYBACK, (HOOKPROC)WDChangeProc, hInst, 0);
Thanks in advance.
Yes U Can ...If U Can ,Dream it , U can do it ...ICAN
-
I am testing one application in vista platform and found that SetWindowsHookEx function fails in VISTA. SetWindowsHookEx return NULL.
journalHook = SetWindowsHookEx(WH_JOURNALPLAYBACK, (HOOKPROC)WDChangeProc, hInst, 0);
Thanks in advance.
Yes U Can ...If U Can ,Dream it , U can do it ...ICAN
from
MSDN
[^]: Return Value If the function succeeds, the return value is the handle to the hook procedure. If the function fails, the return value is NULL. To get extended error information, call GetLastError. Anyway one may guess that elevation is needed there. :)If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
[My articles] -
I am testing one application in vista platform and found that SetWindowsHookEx function fails in VISTA. SetWindowsHookEx return NULL.
journalHook = SetWindowsHookEx(WH_JOURNALPLAYBACK, (HOOKPROC)WDChangeProc, hInst, 0);
Thanks in advance.
Yes U Can ...If U Can ,Dream it , U can do it ...ICAN
-
there are other guys discuss same case in MSDN Forums: Journaling hooks on Vista? [^] Hope it can help you.