🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: Keybd_event with an Ansi Code

#15418
From: Josh Kirkpatrick
Date: Sat, 05 Jul 2003 03:55
24 lines
1944 bytes
> > I have a string ("VK_A") and I would like to use
> > keybd_event with this character.  How to I convert
> > the string to a BYTE, so it can be passed as bVk?
>
> Do you mean that you are accepting such a string as input from the user or
a
> file or such, and need to translate it?

I'm getting it from an input file...

> If so, then you have to write your own parsing algorithm for that, or else
use a lookup table instead.

I was afraid of that;  I had hoped that there was a handy-dandy function
already out there for this purpose....

> Either way, actually there is no actual VK_A define that is declared,
> despite what the API documentation suggests.  You need to use an actual
'A'
> character instead, or make your own define manually:

Thanks for the help -- I'll give that a shot.

~Josh
Technical Details
Message-ID: <3f064c48$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!nntp5.savvis.net!priapus.visi.com!news-out.visi.com!petbe.visi.com!news.tele.dk!news.tele.dk!small.news.tele.dk!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <3f02546f$1@newsgroups.borland.com> <3f061b2a@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,285c18b4f22a6705
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-07-04 21:09:23 PST
From: "Josh Kirkpatrick" <jkirkpat@softhome.net>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3f02546f$1@newsgroups.borland.com> <3f061b2a@newsgroups.borland.com>
Subject: Re: Keybd_event with an Ansi Code
Date: Fri, 4 Jul 2003 23:55:59 -0400
Lines: 26
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: 68.114.164.56
Message-ID: <3f064c48$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1057377352 68.114.164.56 (4 Jul 2003 20:55:52 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!nntp5.savvis.net!priapus.visi.com!news-out.visi.com!petbe.visi.com!news.tele.dk!news.tele.dk!small.news.tele.dk!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail