🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: Virtual Key problem

#16144
From: Nicholas Gessler
Date: Wed, 28 May 2003 18:20
21 lines
1953 bytes
Hmmmnh, maybe so.  But I tried {bracing} and it makes no difference to the
ArrowKeys problem.
I know Form1 is getting the KeyDown event since the color changes to Red.
The ArrowKeys just don't fire.
They DO FIRE in other applications I have written, with identical code, and
my question is, "WHY?"
Nick

"Dumboo" <dumboo@nowhere.com> wrote in message
news:3ed46271@newsgroups.borland.com...
> Arent you missing Someting maybe {}, (maybe not) anyway
>
> void __fastcall TForm1::FormKeyDown(TObject *Sender, WORD &Key,
>       TShiftState Shift)
> {
>    Form1->Color = clRed;
>    if (Key == VK_LEFT) {Form1->Color = clWhite; direction = 3;}
>    if (Key == VK_RIGHT) {Form1->Color = clBlue; direction = 1;}
>    if (Key == VK_UP) {Form1->Color = clGreen; direction = 0;}
>    if (Key == VK_DOWN) {Form1->Color = clYellow; direction = 2;}
> }
Technical Details
Message-ID: <3ed4fd92$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-01!sn-xit-09!sn-xit-08!supernews.com!small1.nntp.aus1.giganews.com!border1.nntp.aus1.giganews.com!nntp.giganews.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
References: <3ed17b8f@newsgroups.borland.com> <3ed46271@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,b34f1e4dec3a67c2
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-05-28 11:56:57 PST
Reply-To: "Nicholas Gessler" <gessler@ucla.edu>
From: "Nicholas Gessler" <gessler@ucla.edu>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3ed17b8f@newsgroups.borland.com> <3ed46271@newsgroups.borland.com>
Subject: Re: Virtual Key problem
Date: Wed, 28 May 2003 11:20:27 -0700
Lines: 23
Organization: UCLA - Geography
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: 4.60.108.106
Message-ID: <3ed4fd92$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1054145938 4.60.108.106 (28 May 2003 11:18:58 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-01!sn-xit-09!sn-xit-08!supernews.com!small1.nntp.aus1.giganews.com!border1.nntp.aus1.giganews.com!nntp.giganews.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail