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, LOTS_OF_MONEY,MSGID_RANDY autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,8bb44fc57f6db2f2 X-Google-Attributes: gid103376,public From: Robert Dewar Subject: Re: Number into String Date: 2000/01/06 Message-ID: <852dmq$vad$1@nnrp1.deja.com>#1/1 X-Deja-AN: 569015631 References: <8517up$t0m$1@green.kreonet.re.kr> <851a0e$tp7$1@green.kreonet.re.kr> <852crn$umf$1@nnrp1.deja.com> X-Http-Proxy: 1.0 x28.deja.com:80 (Squid/1.1.22) for client 205.232.38.14 Organization: Deja.com - Before you buy. X-Article-Creation-Date: Thu Jan 06 15:52:01 2000 GMT X-MyDeja-Info: XMYDJUIDrobert_dewar Newsgroups: comp.lang.ada X-Http-User-Agent: Mozilla/4.61 [en] (OS/2; I) Date: 2000-01-06T00:00:00+00:00 List-Id: In article <852crn$umf$1@nnrp1.deja.com>, reason67@my-deja.com wrote: > In article <851a0e$tp7$1@green.kreonet.re.kr>, > "Jeong, Lae Hyung" wrote: > > I've found !! > > > > S : String := Integer'Image(NUM); > > This thread is kinds fortunate for me to ask a question. I often have > the case where I need to put a number into a string of fixed length. So use the facilities in Text_IO! Text_IO can output an integer in any width or base that you like. If you want to convert leading blanks to zeroes, then either a) write a trivial routine to do this b) use the features in the editing packages of annex G if your compiler supports it (all versions of GNAT support this annex). Annex G allows full edited formatting. For example, you can automatically format the integer 1234567 as ******$12,345.67 if that is what you want. Your routines seem to be reinventing the wheel here :-) Sent via Deja.com http://www.deja.com/ Before you buy.