comp.lang.ada
 help / color / mirror / Atom feed
From: "Jean-Pierre Rosen" <rosen.adalog@wanadoo.fr>
Subject: Re: Text Files
Date: 2000/05/25
Date: 2000-05-25T15:20:29+00:00	[thread overview]
Message-ID: <8gjgbt$s1k$1@wanadoo.fr> (raw)
In-Reply-To: 959260098.454638@hearts.q-net.net.au

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1091 bytes --]


Cameron McShane <cazza@aceonline.com.au> a �crit dans le message : 959260098.454638@hearts.q-net.net.au...
> Hey all
>
> Thanks everyone for your comments and help
>
> It seems that I needed a skip_line before the get_line.
>
>     ie
>     Text_io.skip_line;
>     Text_io.get_line(Filename, Last);
>     Text_Io.Create(
>          File => In_Data,
>          Mode => Text_Io.Out_File,
>          Name => Filename(1..Last));
>
> I was sure I had tried this already, but obviously I was mistaken.
>
Wouldn't you, by any chance, be reading an integer value before ? If you do:
-- assuming proper instantiation of Integer_IO
Get (I);
Get_Line (File_Name, Last);

the first Get will leave you in front of the End_Of_Line, and the Get_Line will read an empty string.
In this case, you don't really need a Skip_Line *before the Get_Line*. What you really need is a Skip_Line *after the Get*. Not
exactly the same thing...

--
---------------------------------------------------------
           J-P. Rosen (Rosen.Adalog@wanadoo.fr)
Visit Adalog's web site at http://pro.wanadoo.fr/adalog






  reply	other threads:[~2000-05-25  0:00 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-05-23  0:00 Text Files Karlene
2000-05-23  0:00 ` Robert Dewar
2000-05-24  0:00   ` Marin D. Condic
2000-05-23  0:00 ` Marin D. Condic
2000-05-23  0:00 ` Cameron McShane
2000-05-23  0:00   ` tmoran
2000-05-23  0:00   ` Ted Dennison
2000-05-23  0:00   ` John English
2000-05-23  0:00   ` Marin D. Condic
2000-05-25  0:00     ` Cameron McShane
2000-05-25  0:00       ` Jean-Pierre Rosen [this message]
2000-05-26  0:00       ` Dale Stanbrough
2000-05-23  0:00 ` Ted Dennison
2000-05-23  0:00 ` David Freshwater
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox