BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
JansM
Calcite | Level 5

With the attached code we construct our table that is afterwards exported into a *.rtf document.

As you can see we use a format ("cellwidth").

 

the table should cover 100% of the horizontal width. We tried different numbers to get the right width of every cell but we can't figure out how sas allocates / computes the cellwidths. As it is not like we dictate with our format.

 

Is there some experience / advice out there?

 

Thank you in advance

 

1 ACCEPTED SOLUTION

Accepted Solutions
ballardw
Super User

For a question like this I would suggest providing some example data, ods destination and options in effect, values for the macro variables and/or remove most of the options that don't have much affect on this appearance such as border colors, borderwidths, font information to reduce the code to the key elements related to the question.

Also if you get any messages in the log that might help.

 

You should also include the actual format, at least enough for the values in the example data. In the format I might look for things that aren't valid for the cellwidth parameter

 

Since the only place I see the $cellwidth format is in a classlev statement what happens if you set a fixed value instead of the format

 

View solution in original post

3 REPLIES 3
ballardw
Super User

For a question like this I would suggest providing some example data, ods destination and options in effect, values for the macro variables and/or remove most of the options that don't have much affect on this appearance such as border colors, borderwidths, font information to reduce the code to the key elements related to the question.

Also if you get any messages in the log that might help.

 

You should also include the actual format, at least enough for the values in the example data. In the format I might look for things that aren't valid for the cellwidth parameter

 

Since the only place I see the $cellwidth format is in a classlev statement what happens if you set a fixed value instead of the format

 

JansM
Calcite | Level 5

thank you for your help!

 

Our problem was mainly that we used ods tagsets.rtf_sample rather than tagsets.rtf.


 

Cynthia_sas
SAS Super FREQ

Hi:

  For an example of using the WIDTH= option, there's an example below. I find that width=100% works, no matter what the destination. For destinations that respect the margin settings (PDF, RTF, PRINTER, TAGSETS.RTF) I find it works better not to "over-control" the width and just use a simple WIDTH=100% on the TABLE statement as shown below. (When I look inside Word, at the margin settings, the margins are correctly set at .5 in all around and the width=100% works as I expect.

 

cynthia

 

set_width.png

SAS Innovate 2025: Register Now

Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 3 replies
  • 1312 views
  • 0 likes
  • 3 in conversation