🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

CBT hooks and exe name

#14063
From: Martin C
Date: Mon, 25 Aug 2003 12:37
17 lines
1442 bytes
I've CBT hook application that help me get notified whenever an new window
is to be created using HCBT_CREATEWND, but I need to know how I can get the
exe name of the newly created window from its handle?

I am using the following code in my CBT hook callback function

 if(nCode >= 0)
{
      if(nCode == HCBT_CREATEWND)
     {
              HWND hwndToNewWindow = (HWND)wParam;

      }
} return CallNextHookEx(g_hShellHook, nCode, wParam, lParam);


thanks
Technical Details
Message-ID: <3f4a0317@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,ee2ed6328ff2f934,start
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-08-25 05:39:30 PST
From: "Martin C" <martinc@aol.com>
Newsgroups: borland.public.cppbuilder.nativeapi
Subject: CBT hooks and exe name
Date: Mon, 25 Aug 2003 04:37:42 -0800
Lines: 19
Organization: V Safe
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: 62.135.27.156
Message-ID: <3f4a0317@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1061815063 62.135.27.156 (25 Aug 2003 05:37:43 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail