🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: Disabling a dialog button results in lost characters.

#14458
From: Gary Setter
Date: Mon, 11 Aug 2003 16:03
28 lines
1966 bytes
"Jim Melsom" <jm@uniserve.com> wrote in message
news:3F370EB6.3DB6@uniserve.com...
> Gary Setter wrote:
> > I have some dialogs with 'Previous page' 'NextPage' buttons. When the
> > current page becomes first, the previous page button is disabled. If I
press
> > escape to exit the dialog at that point, the escape is ignored.
>
> A general way to check for a keystroke at the dialog level is:
>
> - set the form's KeyPreview property to 'true'
> - implement the form's KeyDown event and check for VK_ESCAPE
> - if VK_ESCAPE is pressed set ModalResult to mrCancel (if it's a modal
> dialog)

Hi Jim,

Thanks for the reply.

That didn't help me. The dialog is not getting the escape character without
explicitly setting the focus window as I said in my first post.

Have you seen the same behavior? I can upload a small sample if you have the
time to check it out.

Thanks,
Gary
Technical Details
Message-ID: <3f37be6f@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-06!sn-xit-09!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail
References: <3f34ee12$1@newsgroups.borland.com> <3F370EB6.3DB6@uniserve.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,f7216d587ba9f99f
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-08-11 09:07:29 PST
From: "Gary Setter" <setterg@worldnet.att.net>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3f34ee12$1@newsgroups.borland.com> <3F370EB6.3DB6@uniserve.com>
Subject: Re: Disabling a dialog button results in lost characters.
Date: Mon, 11 Aug 2003 11:03:51 -0500
Lines: 29
MIME-Version: 1.0
Content-Type: text/plain;
 charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
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: 12.84.32.3
Message-ID: <3f37be6f@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1060617839 12.84.32.3 (11 Aug 2003 09:03:59 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-06!sn-xit-09!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail