LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (October 1998, week 4)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Thu, 22 Oct 1998 19:03:29 -0400
Reply-To:     Ray Pass <raypass@WORLDNET.ATT.NET>
Sender:       "SAS(r) Discussion" <SAS-L@UGA.CC.UGA.EDU>
From:         Ray Pass <raypass@WORLDNET.ATT.NET>
Subject:      Re: column labels in %ds2htm
In-Reply-To:  <5Ei2FBAla3L2EwOr@crawfordsoftware.demon.co.uk>
Content-Type: text/plain; charset="us-ascii"

First of all, Thank you to Peter Crawford, Mike Rhoads and Raymond King for their suggestions.

Raymond suggested trying the standard SAS split character, '/', as is used in PROC REPORT and other places. I guess I should have stated that I had already tried this and it didn't do the trick. Thanks anyway Raymond.

Peter and Mike gave me the push I needed to solve the problems. The blank problem was as Peter had noted: when I used ' ' as a label, there was nothing at all to print so SAS reverted to the var name. The answer was to put something there, something non-printable but space occupying. I remembered an answer I got a while back from my SI birdie buddy. I included the following code as my SQL column label, label = '<p>&#160;</p>'. &#160; is an unused print character and that did the trick. I also used it in a format for missing values and it worked like a charm there also. Without it, %ds2htm created borderless cells for missing data.

Mike's suggestion about using <br> also solved the split column header problem. I just used SQL label attributes which looked something like: label = '<p>Top line<br>Bottom line</p>'. Like a charm. Of course, in order for this all to work, you must have encode = n turned on.

Once again, SAS-L to the rescue. Thanks.

Ray

At 07:17 PM 10/22/98 +0100, you wrote: >In article <909076519.2113176.0@vm121.akh-wien.ac.at>, Ray Pass ><raypass@WORLDNET.ATT.NET> writes >>Hi, >> >>I have a few questions about creating customized column labels in %ds2htm. >> >>1) I would like to have certain column headers blank and can't seem to get >>it done. The columns are being generated in PROC SQL with 'label=' >>attributes. I tried using label=' ' and the %ds2htm output just >>substitutes the var name in the column. I do have labels=y in the %ds2htm >>code and other column labels are coming out just fine. >> >>2) Is there any way to force line splits in %ds2htm column labels? I am >>using twidth=0 in my %ds2htm code so that the table is only as wide as it >>has to be and not the whole width of the page. I don't want to use a >>specific twdith because the width of the data elements in some of the >>columns may vary from run to run and the daily output would be too >>unpredictable. I do know the width I need for the columns in which I want >>to have split headers, but I don't think I can apply a specific width to a >>specific column. I tried using a width limiting format= attribute in the >>SQL code, but that had no effect. >> >>I think I could probably (maybe) get what I want by using Style Sheets, but >>that's a topic I haven't mastered yet (but one I know I should). Can >>anybody help? >> >>(Note to my favorite SI birdie - got your ears on good buddy?) >> >>Ray >> >>*------------------------------------------------* >>| Ray Pass voice: (914) 693-5553 | >>| Ray Pass Consulting fax: on request | >>| 5 Sinclair Place | >>| Hartsdale, NY 10530 e-mail: raypass@att.net | >>*------------------------------------------------* > > > >Ray, >I imagine the blank label is seen as a reason to use the varname. >This was an old problem in SAS/Graph overcome by using what I suppose is >now referred to as a "hard blank". > > Label varX ='ff'x; * or some other suitable non-printable char ; > >The technique was used more recently for improving the column label >alignment in tabulate output. > > >-- >Peter Crawford

*------------------------------------------------* | Ray Pass voice: (914) 693-5553 | | Ray Pass Consulting fax: on request | | 5 Sinclair Place | | Hartsdale, NY 10530 e-mail: raypass@att.net | *------------------------------------------------*


Back to: Top of message | Previous page | Main SAS-L page