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.0 required=5.0 tests=BAYES_00,FORGED_HOTMAIL_RCVD2, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,69101b88c05a1b3f X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.68.219.170 with SMTP id pp10mr6587814pbc.1.1339774669583; Fri, 15 Jun 2012 08:37:49 -0700 (PDT) Path: l9ni54040pbj.0!nntp.google.com!news2.google.com!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail From: austin.obyrne@hotmail.com Newsgroups: comp.lang.ada Subject: =?windows-1252?Q?Re=3A_Can_I_Do_this_=96_Help_Badly_Needed=2E?= Date: Fri, 15 Jun 2012 08:36:11 -0700 (PDT) Organization: http://groups.google.com Message-ID: <94d92aa1-8e29-4acd-bf8f-34b6304d1a47@googlegroups.com> References: <70866b0e-472c-4998-b081-51a15fc675dc@googlegroups.com> NNTP-Posting-Host: 109.148.165.193 Mime-Version: 1.0 X-Trace: posting.google.com 1339774669 1999 127.0.0.1 (15 Jun 2012 15:37:49 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 15 Jun 2012 15:37:49 +0000 (UTC) In-Reply-To: <70866b0e-472c-4998-b081-51a15fc675dc@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=109.148.165.193; posting-account=pmkN8QoAAAAtIhXRUfydb0SCISnwaeyg User-Agent: G2/1.0 Content-Type: text/plain; charset=ISO-8859-1 Date: 2012-06-15T08:36:11-07:00 List-Id: On Friday, June 15, 2012 2:06:12 PM UTC+1, austin...@hotmail.com wrote: > I want to write to two external files in turn from within the same program: > > This is the first prompt, > > Ada.Text_IO.Put > (Item => " Please enter the name of the unsorted file >"); > Ada.Text_IO.New_Line(2); > Ada.Text_IO.Put > (Item => " Call it UnSortedNumberFile_n.dat - for whatever 'n' may be >"); > Ada.Text_IO.New_Line(2); > Ada.Text_IO.Put(Item => " "); > Ada.Text_IO.Get_Line(Item => OutFileName,Last => OutNameLength); > Ada.Text_IO.New_Line(2); > Ada.Text_IO.Create(File => OutData, > Mode => Ada.Text_IO.Out_File,Name => OutFileName(1 .. OutNameLength)); > > Name given: UnsortedNumbers_n.dat > > Later on after some more computation in the same program I want to write out to another external file of a different name and I use the same prompt again that is only only slightly changed in the names. > > Second prompt. > > Ada.Text_IO.Put > (Item => " Please enter the name of the unsorted file >"); > Ada.Text_IO.New_Line(2); > Ada.Text_IO.Put > (Item => " Call it SortedNumberFile_n.dat - for whatever 'n' may be >"); > Ada.Text_IO.New_Line(2); > Ada.Text_IO.Put(Item => " "); > Ada.Text_IO.Get_Line(Item => OutFileName,Last => OutNameLength); > Ada.Text_IO.New_Line(2); > Ada.Text_IO.Create(File => OutData, > Mode => Ada.Text_IO.Out_File,Name => OutFileName(1 .. OutNameLength)); > > Name given: SortedNumbers_n.dat > > Is this allowable?. > > Your help would be greatly appreciated > > -adacrypt