The SAS Output Delivery System and reporting techniques

ODS excel Title appears only once

Accepted Solution Solved
Reply
Frequent Contributor
Frequent Contributor
Posts: 131
Accepted Solution

ODS excel Title appears only once

I have SAS code:

 

ODS LISTING CLOSE;

ods excel file="/mnt/nfs/prod/Sched/OpsDeptData/Operations/Reports/LTSS/TEST_HDM.xlsx"

style=Print;

ods excel options(

sheet_name =' HDM_PROVIDERS'

embedded_titles='yes'

EMBEDDED_FOOTNOTES= 'Yes'

sheet_interval="none"

orientation='landscape');

 

Title 'HDM Provider Monthly Report'

RUN;

 

 

%MACRO vLOB(vName1);

 

PROC PRINT DATA=HDM_PROVIDER_&vName1.TRANS NOOBS;

RUN;

%mend vLOB;

%vLOB(0100);

%vLOB(5400);

%vLOB(5410);

%vLOB(7100);

%vLOB(7200);

ODS _ALL_ CLOSE;

 

I need title only appears once not multiple times.

 

 

 


Accepted Solutions
Solution
‎05-03-2018 03:53 PM
PROC Star
Posts: 1,471

Re: ODS excel Title appears only once

Couldn't you just turn it off? e.g.:

title1 'HDM Provider Monthly Report' ;
%vLOB(0100)
title1; *Clear title;

%vLOB(5400)
%vLOB(5410)
%vLOB(7100)
%vLOB(7200)

View solution in original post


All Replies
SAS Super FREQ
Posts: 9,423

Re: ODS excel Title appears only once

Hi:
I believe there is an option to only embed titles once. You may need to refer to the documentation to verify.
Cynthia
Frequent Contributor
Frequent Contributor
Posts: 131

Re: ODS excel Title appears only once

Posted in reply to Cynthia_sas

Oh, I see, Should be related with  ods title option  ?

SAS Super FREQ
Posts: 9,423

Re: ODS excel Title appears only once

Hi,
  It is a sub-option just like embedded_titles or sheet_interval or sheet_name. If you look here
http://go.documentation.sas.com/?docsetId=odsug&docsetTarget=p09n5pw9ol0897n1qe04zeur27rv.htm&docset...
 and search, you should see: EMBED_TITLES_ONCE='on' as a sub-option and you specify it just like you did the other sub-options in your code:
ods excel file=". . ./TEST_HDM.xlsx"
          style=Print
          options(sheet_name =' HDM_PROVIDERS'
                    embedded_titles='yes'
                    embed_titles_once='on'
                    EMBEDDED_FOOTNOTES= 'Yes'
                    sheet_interval="none"
                    orientation='landscape');

 

There are also separate options for print headers and footers that are visible when the sheet is printed.

 

Cynthia

Frequent Contributor
Frequent Contributor
Posts: 131

Re: ODS excel Title appears only once

Posted in reply to Cynthia_sas

Dose not work even added option.

 

ODS LISTING CLOSE;

ods excel file="/mnt/nfs/prod/Sched/OpsDeptData/Operations/Reports/LTSS/TEST_HDM.xlsx"

style=Print;

ods excel options(

sheet_name =' HDM_PROVIDERS'

embedded_titles='YES'

embed_titles_once='ON'

sheet_interval="none"

orientation='landscape'

 

);

RUN;

title 'TEST';

%MACRO vLOB(vName1);

 

PROC PRINT DATA=HDM_PROVIDER_&vName1.TRANS NOOBS;

RUN;

%mend vLOB;

%vLOB(0100);

%vLOB(5400);

%vLOB(5410);

%vLOB(7100);

%vLOB(7200);

ODS _ALL_ CLOSE;

 

Solution
‎05-03-2018 03:53 PM
PROC Star
Posts: 1,471

Re: ODS excel Title appears only once

Couldn't you just turn it off? e.g.:

title1 'HDM Provider Monthly Report' ;
%vLOB(0100)
title1; *Clear title;

%vLOB(5400)
%vLOB(5410)
%vLOB(7100)
%vLOB(7200)
Frequent Contributor
Frequent Contributor
Posts: 131

Re: ODS excel Title appears only once

thanks, this one works.

 

☑ This topic is solved.

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

Discussion stats
  • 6 replies
  • 328 views
  • 0 likes
  • 3 in conversation