BookmarkSubscribeRSS Feed
Mgarret
Obsidian | Level 7

Hi all--

I'm having some trouble writing titles into 3 proc report statements which all appear on one page. Any advice on to add the titles in would be greatly appreciated. Thanks!

title1 'Special Medical Review Total Score';


proc report

data=All_Spec_Med_Qs_TotalScore nowd headline headskip

style(column)={just=c font_size=11pt font_face= 'Arial Narrow'cellwidth=2in}

style(header)={font_size=11 pt font_face= 'Arial Narrow' FONT_WEIGHT =BOLD background=cxcccccc};

column    totalAwarded Total_Possible  Final_score ;

define Final_score / display

style(column)={ cellwidth=1.8in};

run;

title2  Special Medical Review Quality Score;

proc report

data=Spec_Med_Quality_Qs_TotalScore nowd headline headskip

style(column)={just=c font_size=11pt font_face= 'Arial Narrow'cellwidth=2in}

style(header)={font_size=11 pt font_face= 'Arial Narrow' FONT_WEIGHT =BOLD background=cxcccccc};

column totalAwarded Total_Possible  Final_score;

define Final_score / display

style(column)={ cellwidth=1.8in};

run;

title3 Special Medical Review Compliance Score ;

proc report

data=Spec_Med_Comp_Qs_TotalScore  nowd headline headskip

style(column)={just=c font_size=11pt font_face= 'Arial Narrow'cellwidth=2in}

style(header)={font_size=11 pt font_face= 'Arial Narrow' FONT_WEIGHT =BOLD background=cxcccccc};

column totalAwarded Total_Possible  Final_score;

define Final_score / display

style(column)={ cellwidth=1.8in};

run

5 REPLIES 5
ballardw
Super User

You don't say what your problem actually is but I'm going to guess that you get two lines of title for the second report and only want one and are getting three lines for tha last one.

Title is sort of a space holder with up to 9 lines. And all currently defined lines will show. I suspect that you want to use TITLE1 for each of your PROC REPORT calls to show one main line of title.

For an alternative appearance try this:

Title1 "Special Medical Review";

Title2 "Total Score";

before the second proc report

Title2 "Quality Score";

and before the third

Title2 "Compliance Score";

Abud
Calcite | Level 5

Hi,

If you are using ODS PDF, you can do something like this:

ods pdf text= "Special Medical Review Total Score"; (for each one);

Cynthia_sas
SAS Super FREQ

Hi:

  I believe this question probably should have been posted in the ODS and Reporting forum, not the ODS and Graphics forum. Unless your code has some SAS/GRAPH or ODS GRAPHICS.

  You did not say what your destination of interest was -- RTF, PDF or HTML. Titles are GLOBAL in nature. You can have up to 10 titles.. What ODS statements are you using for your report? In the LISTING destination, these 3 reports would not print on 1 page. So I figure you are using either PDF, RTF or HTML.

  You have received some good information about SAS title statements in general and for dealing with ODS PDF in particular. I'd suggest you investigate TITLE statements in a bit more depth and possibly post ALL of your code, including ODS statements, so we can understand the whole picture. TITLE statements can behave differently in different destinations and their behavior is also dependent on the other options you are using (such as BODYTITLE or STARTPAGE or ...)

cynthia

shivas
Pyrite | Level 9

Hi,

If I guess correctly,you are getting the all three titles in all the reports which you want to restrict.Try this..

title 'test1';

proc print data=sashelp.class;run;

title '';

title 'test2';

proc print data=sashelp.class;run;

title '';

title 'test3';

proc print data=sashelp.class;run;

title '';

Thanks,

Shiva

Eva
Quartz | Level 8 Eva
Quartz | Level 8

Hi Mgarret,

if you want to put all report tables on one page then don't use title. Use ods pdf text=""; instead.

ods pdf text="your first title";

proc report....;

run;

ods pdf text="your second title";

proc report...;

run;

etc.

Best wishes

Eva

SAS INNOVATE 2024

Innovate_SAS_Blue.png

Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. 

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.

Get the $99 certification deal.jpg

 

 

Back in the Classroom!

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

View all other training opportunities.

Discussion stats
  • 5 replies
  • 1100 views
  • 0 likes
  • 6 in conversation