🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

How to get first control in tab order

#12121
From: Bruce Rhoades
Date: Mon, 29 Dec 2003 15:08
21 lines
1954 bytes
I am having a problem concerning getting a pointer to a control that is
first on a dialogs tab order. I am trying to write a utility function that
accepts an HWND and sets focus to that control. I would like to use
something like FindNextControl, but that function is protected and not
accessible in my utility function.

Any ideas on what I can do here? I thought about creating a custom message
to do this, then send that message to the dialog where I can then call
FindNextControl to do the work, but that seems to be an unnecessary amount
of work. Plus I don't want to have to write MessageMaps for all my dialogs
to handle this message (I do have a base dialog class, but for some reason
when I put the message map in there, the handler does not get called - I
must put it in all my derived dialogs classes which would be a pain!!).

Note that I have also tried to send a NextDlgCtrl to the dialog but that
didn't work.

Any help getting this to work, and/or why my base dialog message hanlder
doesn't get called would be appreciated.

- Bruce
Technical Details
Message-ID: <3ff044aa@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!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,cf151fabf6b9ddca,start
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-12-29 07:39:37 PST
From: "Bruce Rhoades" <bruce.rhoades@gdsinc.com>
Newsgroups: borland.public.cppbuilder.nativeapi
Subject: How to get first control in tab order
Date: Mon, 29 Dec 2003 10:08:52 -0500
Lines: 25
Organization: GDS
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.00.2314.1300
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300
NNTP-Posting-Host: 66.200.122.38
Message-ID: <3ff044aa@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1072710826 66.200.122.38 (29 Dec 2003 07:13:46 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail