Date: Thu, 3 Jul 2003 16:46:51 -0400
Reply-To: Sigurd Hermansen <HERMANS1@WESTAT.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Sigurd Hermansen <HERMANS1@WESTAT.COM>
Subject: Re: Writing a text file with "if ... then put" statements
Content-Type: text/plain; charset="iso-8859-1"
The 'header= ...' option only works when writing print files. Include the
keyword PRINT in the FILE statement.
From: Tyler Barbour [mailto:sim7396@HOTMAIL.COM]
Sent: Thursday, July 03, 2003 4:13 PM
Subject: Writing a text file with "if ... then put" statements
I want to create a text file using a FILE statement. The code I used
resulted in the header line being printed several times, but I only
want it printed once at the top of the page (my text file will seldom,
if ever, be longer tnan one page)
This is what I tried. What did I do wrong?
file "c:\lola.txt" header=pagetop;
if (1) then put "This is a test";
if (0) then put "This will not print";
if (1) then put "This is another test";
put @15 "This is the header line";