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.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,8dd8ee71ca4e5206 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-10-03 11:50:43 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!newsfeed.dacom.co.kr!newsfeed.hananet.net!news-xfer.nuri.net!sn-xit-03!sn-xit-06!sn-post-01!supernews.com!corp.supernews.com!not-for-mail From: "Matthew Heaney" Newsgroups: comp.lang.ada Subject: Re: Newbie question on Ada TExt_IO Date: Thu, 3 Oct 2002 14:50:13 -0400 Organization: Posted via Supernews, http://www.supernews.com Message-ID: References: <93d4dcd4.0210031020.b0cca2b@posting.google.com> X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 X-Complaints-To: abuse@supernews.com Xref: archiver1.google.com comp.lang.ada:29497 Date: 2002-10-03T14:50:13-04:00 List-Id: "Justin" wrote in message news:93d4dcd4.0210031020.b0cca2b@posting.google.com... > > I'm doing TextIO from the command prompt. But I'm having difficulty > validating the input. For example I'm asking the user to enter a > number, let's say I'm expecting an integer between 1 and 6 I recommend that you do *not* use Get to consume the value. Instead, use Get_Line to consume the entire line, and then either use Integer'Value to convert the text to an integer, or use the version of Get that reads from a string buffer.