From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,2fab47507cfaddb7 X-Google-Attributes: gid103376,public From: Matthew Heaney Subject: Re: Ord Function HELP Please HELP HELP HELP Date: 1998/12/14 Message-ID: #1/1 X-Deja-AN: 422001792 Sender: matt@mheaney.ni.net References: <36756d56.12552904@news.smartlink.net> <36748403.109022624@news.pacbell.net> <3679891d.19665290@news.smartlink.net> NNTP-Posting-Date: Sun, 13 Dec 1998 19:56:42 PDT Newsgroups: comp.lang.ada Date: 1998-12-14T00:00:00+00:00 List-Id: John_Lin@paramount.com (Johnny) writes: > On Mon, 14 Dec 1998 03:21:52 GMT, tmoran@bix.com (Tom Moran) wrote: > > >Do you mean integer'image(5) > >which gives " 5"? or do you mean "fifth"? > > > Hi, Thank You for your msg, > I'm a new ada coder, and I have run into a small problem, I can't find > a function that will return the ASCII converted number for any key > pressed on the keyboard, example: user hits the backspace key, I > would like to be able to catch the key however, without a function to > convert the ASCII representation to #8, we would have no idea that he > pressed the backspace. In VB it's the "CHR" function in Pascal it's > the "Ord" function, ADA95 does not list this function anywhere that I > can find, I am hoping it is built into the compiler, however, I think > I may need to dload a Package. > > Any Help is much appreciated, > > Thnx ,Johnny Use Get_Immediate to deliver the character corresponding to the key, then convert that character to its integer code by using Character'Pos.