From a different application, I tried to get other application handle using "HINSTANCT hInst = GetWindowLong(hWnd, GWL_HINSTANCE);" which I am using in the function "HHOOK hHook = SetWindowsHookEx(WH_KEYBOARD, KeyboardProc, hInst, GetWindowThreadProcessId(hWnd, NULL));". But the handle returned by "SetWindowsHookEx()" is NULL (because of 'hInst'). Could someone help me to resolve this problem by suggesting a alternate solution for this? Thanks in Advance, Rajarajan V. Rajarajan Veerichetty. IBM Software Labs, Bangalore Mobile: +91-0-9845443206