Date: Mon, 8 Jan 2007 15:59:24 -0600
Reply-To: Yu Zhang <zhangyu05@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Yu Zhang <zhangyu05@GMAIL.COM>
Subject: Re: QUICK question regards to wrapping the date
In-Reply-To: <e3737e640701081339m35542781odf1fe1c477dfecda@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
If you want to break a long line into several pieces, you have to use HTML
tag <br>. look at the example below: I replace all the ~ with <br> and tell
formater to interpret the html tag using option :proctectspcialchar=off
HTH
Yu
data test;
string='~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7
2270!
/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~5/10/2001~5/10/2001~5/10/2001~5/10/2001~8
2270! /16/2001~8/17/2001~8/16/2001~8/16/2001~7/14/2005';
string=tranwrd(string,'~','<br>');
run;
ods html file= 'c:\test.html';
proc report data=test nowd
style (column) = [protectspecialchars=off];
col string;
define string/display flow width=40
style={cellwidth=2.5in} flow;
run;
ods html close;
On 1/8/07, srijana sharma <srijana98@gmail.com> wrote:
>
> I can see text wrapped in my output window. But when I see my html output
> it is still in single line. I tried rtf. and changed width.
> ~8/29/2005~8/29/2005~1/31/2003~7/16/2003~8/29/2005~8/29/2005~8/29/2005~8/29/2005~8/29/2005~9/24/2003~7/16/2006~7/16/2003~9/24/2003~8/29/2005~8/29/2005~2/2/2003~1/31/2003~1/30/2003~2/2/2003~1/30/2003~1/31/2003~8/29/2005~8/29/2005~8/29/2005~8/29/2005~8/29/2005~8/29/2005
>
> Did you try on html output delivery.
>
>
>
> On 1/8/07, Yu Zhang <zhangyu05@gmail.com> wrote:
> >
> > Not sure what are you trying to accomplish. you kept say it is not
> > working and I test it with your sample string. it did wraped. couldn't
> > replicate your problem. May be you need to provide more information about
> > your code and data, or a bing picture of your goal.
> >
> >
> > data test;
> > string='~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~5/10/2001~5/10/2001~5/10/2001~5/10/2001~8/16/2001~8/17/2001~8/16/2001~8/16/2001~7/14/2005';
> >
> > run;
> >
> > ods rtf file= 'c:\test.rtf';
> > proc report data=test nowd;
> > col string;
> > define string/display flow width=40
> > style={cellwidth=2.5in} flow;
> > run;
> > ods rtf close;
> >
> >
> >
> > On 1/8/07, srijana sharma <srijana98@gmail.com > wrote:
> > >
> > > It is still not wrapping. May be being ~ and / is confusing SAS
> > >
> > > On 1/8/07, srijana sharma <srijana98@gmail.com > wrote:
> > > >
> > > > still it is not working
> > > > do I have to do
> > > >
> > > > options
> > > > ls=*72* nocenter;
> > > >
> > > >
> > > > On 1/8/07, srijana sharma <srijana98@gmail.com > wrote:
> > > > >
> > > > > width worked
> > > > >
> > > > > On 1/8/07, Yu Zhang <zhangyu05@gmail.com> wrote:
> > > > > >
> > > > > > specify the cellwith=2.5in (Adjust it if needed) and try again.
> > > > > >
> > > > > > On 1/8/07, srijana sharma <srijana98@gmail.com > wrote:
> > > > > > >
> > > > > > > oh ok I did rtf and used style and stuff still it wont wrap
> > > > > > >
> > > > > > > On 1/8/07, Yu Zhang <zhangyu05@gmail.com> wrote:
> > > > > > > >
> > > > > > > > I couldn't recall who said to me that the orientation system
> > > > > > > > option may not work for HTML destination. you can give a try anyway.
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > On 1/8/07, srijana sharma <srijana98@gmail.com > wrote:
> > > > > > > > >
> > > > > > > > > I send out put to HTML destination. I will try other stuff
> > > > > > > > > you said
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > On 1/8/07, Yu Zhang <zhangyu05@gmail.com> wrote:
> > > > > > > > > >
> > > > > > > > > > Darsu,
> > > > > > > > > >
> > > > > > > > > > One way is to send your ouput to RTF ,pdf or HTML
> > > > > > > > > > destination, instead of the default listing window. Then you can specify the
> > > > > > > > > > orientation option as landscape and aslo you can use style option to refine
> > > > > > > > > > the font-size in your output.
> > > > > > > > > >
> > > > > > > > > > look up:1. option orientation=landscape
> > > > > > > > > > 2. style element for proc report.
> > > > > > > > > >
> > > > > > > > > > one example for redefining the font size:
> > > > > > > > > >
> > > > > > > > > > define PI*** /order left width=10 'PatientID^(pids)'
> > > > > > > > > > flow
> > > > > > > > > > style(column)={font_size=8pt};
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > HTH
> > > > > > > > > >
> > > > > > > > > > Yu
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > On 1/8/07, Darsu <srijana98@gmail.com> wrote:
> > > > > > > > > > >
> > > > > > > > > > > Hi users
> > > > > > > > > > >
> > > > > > > > > > > I used proc print but could not wrap this long record.
> > > > > > > > > > >
> > > > > > > > > > > After that I used proc report and used flow and stuff
> > > > > > > > > > > but still I am
> > > > > > > > > > > having problem wrapping this specific date record.
> > > > > > > > > > > Help me
> > > > > > > > > > > define PI*** /order left width=10 'PatientID^(pids)'
> > > > > > > > > > > flow;
> > > > > > > > > > >
> > > > > > > > > > > Is there any quick way to wrap the text.
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > > This all the dates stays on one row.
> > > > > > > > > > >
> > > > > > > > > > > ~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~7/14/2005~5/10/2001~5/10/2001~5/10/2001~5/10/2001~8/16/2001~8/17/2001~8/16/2001~8/16/2001~7/14/2005
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
|