The SAS Output Delivery System and reporting techniques

Aligning the table in the middle

Reply
Contributor
Posts: 34

Aligning the table in the middle

Hi

 

I want the table that is printed to be in the middle of the page. How do I do that?

 

 

proc template;
define style formel1;
parent = styles.printer;
class body / backgroundimage = "\\blabla.jpg";
style fit/
fontsize = 4
fontfamily = impact;

STYLE SystemTitle /
 FONT_FACE = "Times New Roman, Times "
 FONT_SIZE = 6
 FONT_WEIGHT = bold
 FONT_STYLE = italic;
 STYLE SystemFooter /
 FONT_FACE = "Times New Roman, Times "
 FONT_SIZE = 6
 FONT_WEIGHT = bold
 FONT_STYLE = italic
;

end;
run;
GOPTIONS device=ACTXIMG;
/*Lager Pdf og macro i mail teksten*/

ods listing close;

options orientation=landscape topmargin="0.5cm" ;
options pdfsecurity=none
pdfpassword=(open="SCB");
ods pdf file="\\blablaba_&Periode..pdf" style=formel1 STARTPAGE=NEVER;

/*   STARTER MED RESULTATENE */
Title "apps";

proc print data=work.paidoutratio_m NOOBS ;
run;

;
ods pdf startpage=now; 



ods _all_ close;

ods listing close;

 

Super User
Posts: 9,671

Re: Aligning the table in the middle

options orientation=landscape topmargin="0.5cm"  center ;
Contributor
Posts: 34

Re: Aligning the table in the middle

Perhaps I was a bit unclear

 

 

I want the table to be in the middle of page, making it just as long from the top of the page to the bottom

SAS Super FREQ
Posts: 8,740

Re: Aligning the table in the middle

Hi:

  For ODS PDF, you would need to adjust your top and bottom margins for the placement you want. Or, investigate ODS LAYOUT to see if vertical alignment is possible. If your table always has the exact same number of rows, then the ABSOLUTE Layout should let you adjust the vertical placment. The CENTER system option is for horizontal alignment within the boundaries set by the right/left margins.

cynthia

Contributor
Posts: 34

Re: Aligning the table in the middle

 

I have tried this but since I also have a background picture this picture is being moved downwards as well...

SAS Super FREQ
Posts: 8,740

Re: Aligning the table in the middle

Hi: The documentation for BACKGROUNDIMAGE does not indicate that it is supported by ODS PDF. Please refer to this doc page: http://support.sas.com/documentation/cdl/en/odsproc/69834/HTML/default/viewer.htm#n19a4b40swc766n18q...

The doc says that BACKGROUNDIMAGE is only supported by "Restriction The BACKGROUNDIMAGE= attribute is valid in markup family destinations, the PCL destination, and the PS destination. It is also valid in the TAGSETS.RTF destination, but the background image applies to the RTF document and not to a table or a table cell. "

Are you using BACKGROUNDIMAGE, when you only need to have a logo or picture appear above the table??? Either way, you may want to work with Tech Support on this. If you are using ODS PDF, then I am not sure you can use BACKGROUNDIMAGE the way you have attempted.

cynthia
Ask a Question
Discussion stats
  • 5 replies
  • 166 views
  • 0 likes
  • 3 in conversation