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.6 required=5.0 tests=BAYES_05,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,4a3d58309fdb60b2 X-Google-Attributes: gid103376,public From: Kas_le_chat Subject: Re: loop and constraint error(Thanks that fix ..it all) Date: 1998/10/13 Message-ID: <3622BAED.2A39@attcanada.net>#1/1 X-Deja-AN: 400467252 Content-Transfer-Encoding: 7bit References: <3620E968.526B@attcanada.net> <36229967.7D78@attcanada.net> Content-Type: text/plain; charset=us-ascii MIME-Version: 1.0 Reply-To: kasino@attcanada.net NNTP-Posting-Date: Tue, 13 Oct 1998 02:19:13 GMT Newsgroups: comp.lang.ada Date: 1998-10-13T00:00:00+00:00 List-Id: Matthew Heaney wrote: > > Kas_le_chat writes: > > > Thanks a lot. That fix the constraint_error and the loop problem. > > I still have the data_error problem.When i provoque it, the program go > > crazy and loop for ever. Any sugestion is welcome and thanks again. > > Do a Skip_Line in the exception handler. This will move past the > current line (which has the bad data). Thanks a lot it work. This is the code : begin Entrer_Quantite : --nom de la boucle. loop begin Put("Entrez la quantitee de pomme, MINIMUM 0 et MAXIMUM 50 Kg:"); es_reels.Get(v_pommes); exit Entrer_Quantite; exception when constraint_error | data_error => Put_Line("Un nombre entre 0.0 et 50.0"); when others => text_io.skip_line; end; end loop Entrer_Quantite; Thanks to all who gived me some solutions. Kas