hi all .could any one tell me how i can get the HookControl ? I want to run an example and it tell me to dragg HookControl to my main form but dont know where to to get it . Looking forward for replies.Thanks
Printable View
hi all .could any one tell me how i can get the HookControl ? I want to run an example and it tell me to dragg HookControl to my main form but dont know where to to get it . Looking forward for replies.Thanks
Sorry I don't understand... What is a "hookcontrol" ?
here is what you're looking for.
it's the latest versions i could find.
every thing is there, just read instruction.
Thanks for replies.Whatsup i came across same example as the one you uploaded . I tried to run yours again but i keep getting these errors when runing the project:
during loading the project i get this error:
And then when i press the hook button i get this error:Quote:
Errors during load .Refer to 'c:\HookControle\TestHook\form1.log'for details
pointing at :Quote:
Compile error:
Method or data member not found
content of form1.logQuote:
.GetTopLevelHandle(ParentCaption)
Quote:
Line 12: Class HookCtrl.HookControl of control HookControl was not a loaded control class.
Line 15: The property name _ExtentX in HookControl is invalid.
Line 16: The property name _ExtentY in HookControl is invalid.
Line 15: The property name _ExtentX in HookControl is invalid.
Line 16: The property name _ExtentY in HookControl is invalid.
I i placed HookControl.ocx and MainHook.dll in system32 folder but still the above errors don't go away. Could you help me fix these erros and be able run and learn from attached project?
Have you registered them? You need to register them using regsrvr.
See this link on how to register it... (Ignore the part which talks about foxpro... just see the syntax)
http://support.microsoft.com/kb/146219
Ok, go to Menu Project~~>References and see if you can set a reference to HookControl.ocx.
koolsid i just checked i couldn't find any refrence to HookControl.ocx at all!
You need to click on the browse button in the dialog box and select the .ocx file in your systems32 folder :)
You need to select "ActiveX Controls (*.Ocx)" in the file type in that browse box. If I am not wrong then the default is "Type Libraries (*.olb,*.tlb blah blah)"
i was able to select it but when i click open it doesn't show in the list !!
Sorry I don't have vb6 so I am using a VBA Reference box. It will give you a basic idea of what I am talking about...
Oh you posted while I was uploading a snapshot of what i meant :)
Show me a snapshot of your reference box and your toolbox after you have selected it...
I was browsing through the zip file to see if I was missing something but I guess I will have to wait till I try it on my laptop. I don't have vb6 in the office :(
here are 2 projects that i just checked and fixed
hookdemo -
the second project is just for building the ocx with no errors,Code:* open notepad,
* compile/run the app
* type notepad title, (in english version, it's: Untitled - Notepad)
you must type the title correct.
* type something in notepad, you should see only XXX
because you hooked it.
so you can use it with other samples.
whatis up thanks. i was only able to run the hookDemo . So inorder to to hook to any external application i need to have the handle of the controle in the application ?did this program inject any dll to the external application? where to get the source code for that dll that has been injected ?
Furthermore, I want to do something useful using hooking such as hooking to this external application winsock API "recv" and reads the incoming data and fill it in textbox in my own application. Could you tell me how i can modify this HookDemo project to just do that for me.Looking forward for replies.Thanks