BookmarkSubscribeRSS Feed
twildone
Pyrite | Level 9

 

Hi...I am trying to insert a line to seaprate the titles from the body of the content of the report and I end up with only a dash at the begiining of the line but doesn not go across the entire page. Below is part of the code that I am using. I am wondering if I am missing something? Thanks.

 

ODS _ALL_ CLOSE;

ODS LISTING CLOSE;

ODS NORESULTS;

 

OPTIONS ORIENTATION=PORTRAIT NOCENTER NODATE NONUMBER

                                TOPMARGIN=".5IN"

                                BOTTOMMARGIN=".5IN"

                                LEFTMARGIN=".5IN"

                                RIGHTMARGIN=".5IN";

%LET RSTR = %STR( );

%LET TSTR = %SYSFUNC(REPEAT(&RSTR,50));

 

ODS ESCAPECHAR='^';

ODS PDF FILE="%sysfunc(pathname(project))\&FILENAME Report (&rundate).PDF" STYLE=JOURNAL NOTOC BOOKMARKGEN=NO BOOKMARKLIST=NONE;

 

TITLE1 JUSTIFY=LEFT '^S={PREIMAGE="U:\PERSONAL\LOGO1.GIF"}';

TITLE2 JUSTIFY=CENTER BOLD HEIGHT=12PT FONT="Arial" "Listing of Items";

TITLE3 JUSTIFY=CENTER BOLD HEIGHT=12PT FONT="Arial" "For the Department in Descending Order of Quantity Units";

TITLE4 JUSTIFY=CENTER BOLD HEIGHT=12PT FONT="Arial" "For the Period of January 1 to December 31";

TITLE5 " ";

TITLE6 "^{style[bordertopwidth=2px bordertopcolor=black] &tstr}";

1 REPLY 1
Ksharp
Super User

Try this one :

 

ods pdf file='/folders/myfolders/x.pdf';
ods escapechar='~';
TITLE1  j=l "  "  j=r "  "  ;
TITLE2 "~{style[bordertopwidth=2px bordertopcolor=black]} ";
proc print data=sashelp.class;run;
ods pdf close;

 

 

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 803 views
  • 0 likes
  • 2 in conversation