🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #15988

Re: Problem setting a system wide hook. Help please?

#15988
From: Bruce Salzman
Date: Tue, 03 Jun 2003 15:41
25 lines
1937 bytes
> ;o) I'm kinda new to C++. I used Java before. I guess you advise me to
> add "#define STRICT" on top of the page, is that correct? Still
> nothing...

No, go to Project|Options and select the Directories/Conditionals tab. Then
enter ;STRICT in the Conditional Defines edit box after _DEBUG.
That way it is defined before compilation begins.

>
> The strange thing is: when I set a breakpoint at "instanceHandle =
> hinst;" or anywhere else in the DLLEntryPoint it does not break, so it
> isn't even being called yet. How do I get it to load?

It reached the break point when I tried at the line

   instanceHandle = hinstDLL;

but the assignment doesn't work! Apparently, the name instanceHandle is
defined somewhere else in one of the many include files that #include
<windows.h> pull in. Try another name for your variable, like

HINSTANCE HookInstanceHandle;

Regards,
Bruce
Technical Details
Message-ID: <3edcc1c7$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!priapus.visi.com!news-out.visi.com!petbe.visi.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail
References: <3edb1935$1@newsgroups.borland.com> <3edbca72$1@newsgroups.borland.com> <3edc7108@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,64ef2e065c89c8be
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-06-03 08:51:34 PST
From: " Bruce Salzman" <bruce@nospam.org>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3edb1935$1@newsgroups.borland.com> <3edbca72$1@newsgroups.borland.com> <3edc7108@newsgroups.borland.com>
Subject: Re: Problem setting a system wide hook. Help please?
Date: Tue, 3 Jun 2003 10:41:59 -0500
Lines: 27
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: 65.28.131.87
Message-ID: <3edcc1c7$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1054654919 65.28.131.87 (3 Jun 2003 08:41:59 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!priapus.visi.com!news-out.visi.com!petbe.visi.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail