The SAS Output Delivery System and reporting techniques

Justifying text segments in an ODS TEXT statement

Accepted Solution Solved
Reply
Regular Contributor
Posts: 179
Accepted Solution

Justifying text segments in an ODS TEXT statement

Hi,

 

I have some ODS TEXT statements in an absolute layout that need page #s on the right margin.  I can do that with 2 regions, but wondered if it can be done with one.  What I tried was:

 

ods region y=1.5in x=.25in width=10in height=.25in;

ods text = "^{style[fontsize=8pt]All results are preliminary}  ^{style[just=r]Page 1 of 4}";

 

So then I added a width= parm to the 2nd style:

 

ods text = "^{style[fontsize=8pt]All results are preliminary}  ^{style[just=r width=10in]Page 1 of 4}";

 

The report is in landscape mode, so the lengths work fine in this context.  ?

 

Using current version 9.4 TS1M3 of SAS.

 

Thanks!

 

--Ben

 

 


Accepted Solutions
Solution
‎08-03-2016 09:56 AM
SAS Super FREQ
Posts: 8,819

Re: Justifying text segments in an ODS TEXT statement

Hi:
I am not sure that what you want is possible. I seem to remember something about PDF that what is in ODS TEXT is one cell and one cell has one justification. You might want to double check with Tech Support to see if I am remembering correctly.

cynthia

View solution in original post


All Replies
Solution
‎08-03-2016 09:56 AM
SAS Super FREQ
Posts: 8,819

Re: Justifying text segments in an ODS TEXT statement

Hi:
I am not sure that what you want is possible. I seem to remember something about PDF that what is in ODS TEXT is one cell and one cell has one justification. You might want to double check with Tech Support to see if I am remembering correctly.

cynthia
Regular Contributor
Posts: 179

Re: Justifying text segments in an ODS TEXT statement

Ah.  Ok, that explains it.  Will just use 2 regions.  Thanks!

 

--Ben

Super User
Posts: 9,867

Re: Justifying text segments in an ODS TEXT statement

You can pad some blanks in it.

ods escapechar='^';
ods text = " All results are preliminary %sysfunc(repeat(^_,40))  Page 1 of 4";
proc print data=sashelp.class;run;


Regular Contributor
Posts: 179

Re: Justifying text segments in an ODS TEXT statement

Hi Xia,

Actually that's exactly what I did. That creates other issues though that can be problematic.

Will just use 2 regions. That way each can have its unique justification.

Thanks!

--Ben
Super User
Posts: 9,867

Re: Justifying text segments in an ODS TEXT statement

Sorry. I don't know. I am not familiar with ODS LAYOUT.


☑ This topic is solved.

Need further help from the community? Please ask a new question.

Discussion stats
  • 5 replies
  • 445 views
  • 0 likes
  • 3 in conversation