Click to See Complete Forum and Search --> : need a few help about Hooking


escap3
July 21st, 2008, 12:28 PM
Hello friends .
today, I thought If I can write a program that uses Hook functions I can learn hooking as well .
well, I think it can be a good idea to write a program to hooking Microsft word.
I want to write a program that whenever I take a Save As from my Document in MS Word, when I save it as "1.Doc" my program uses some Hook functions & save it as "2.Doc" .
unfortunately, I never used Hook Functions but I know what can they do & read some articles about Hooking .
now, I need your help . can you please give me some information about these functions, how to use them, & finally how can I write this program also I want to know which hooking functions should be apply to my program .
if some sample source codes are available it can be good .
thanks .

- escap3

fred100
July 21st, 2008, 02:18 PM
Read MSDN (SWHE, ...)
Everything is there, with tons of samples (KB , articles, etc) for all types of hooks.

escap3
July 21st, 2008, 03:32 PM
thanks fred, it's good but i'm very new to Hooks and now i'm hazy .
could you please give me a little more help ?

thnx

- escap3

Afr0
July 22nd, 2008, 08:37 PM
Here you go, this is a reference on hooks that i found in my bookmarks.
http://home.socal.rr.com/samhobbs/VC/Hooks.html

Also, the type of hooking you want to do is not a simple one, and if you do not understand basic hooking even, then you're better of learning from the bottom up. The "best" outcome here is that you get a piece of working code that you have no idea how it works, and then you've gained nothing in the end.

Edit: I realized this might sound a bit rude, that was not my intention.

Igor Vartanov
July 24th, 2008, 04:46 AM
now, I need your help . can you please give me some information about these functions, how to use them, & finally how can I write this program also I want to know which hooking functions should be apply to my program .In other words, you're asking for a course of lessons on various programming aspects including Windows architecture basics, Windows native hooks and code injection, system call interception and possibly interprocess communication as well, as long as your "Word trick" thing looks much more tricky than you think of it. Do you have a faintest idea about what time that course would take? And correspondingly what money it would cost? ;)