Hi,
Below is the code I am using to generate the PDF, I am in need of removing the level two bookmarks from the output. The highlited bookmarks from the below image. I tried multiple ways but I am not succesful. Please advise how to completely remove the highlited bookmarks.
ods proclabel='TOC';
proc report nowd data=toc contents="" ;
columns node tlg combtit;
define node / group noprint;
define tlg / display ' ' style(column)=[asis=on cellwidth=1.3in just=l color=blue] style(header)=[just=l] ;
define combtit / display ' ' style(column)=[asis=on cellwidth=7.7in just=l color=blue] style(header)=[just=l] ;
break before node / contents="" page;
run;
Your code looks right.
data class;
set sashelp.class;
retain id 1;
run;
ods pdf file='c:\temp\temp.pdf';
ods proclabel='TOC';
proc report nowd data=class contents="" ;
define id / group noprint;
define name / display ' ' style(column)=[asis=on cellwidth=1.3in just=l color=blue] style(header)=[just=l] ;
break before id / contents="" page;
run;
ods pdf close;
So I guess I am missing something in proc document procedure which generates bookmarks for next pages or items.
So is it the proc document procedure that generates bookmarks for every new item in a PDF ?
Hi,
If my code looks right, I dont get the output like you have. I still get those extra "Table 1 and Table 2" bookmarks. in my output using the same code.
I am not sure how to control those second level nodes. I tried solutions from https://support.sas.com/kb/31/278.html here as well. but still i get them.
Please advise.
Thank you
Bharath
Yeah, This is from proc document to assign labels to each object (TLF's). I am able to assign labels but cant suppress the next level bookmarks. I sthere a way to achieve this.
make temp;
dir \temp#1;
%do by=1 %to &bycnt;
%let thispath=%scan(&bylist,&by,|);
copy \itemlib.&thisitem.&thispath to ^;
%end;
setlabel \work.&thisitem\temp#1 "&bookmark";
run;
Sorry . I am not familiar with proc documentation. Maybe @Cynthia_sas know it.
Hmm ok, I tried a lot of her @Cynthia_sas answers from the communities. Most of them are from report. May be @Cynthia_sas if you can help me achieve this. Would be of great help. Do you want me to raise a diferent question and tag you.
Hi:
You don't show ALL of your code, ALL the code, including the original procedures and ALL the PROC DOCUMENT code. No on can run your code without any data. However, I always recommend that you get all your code working to make the structure you want in PROC DOCUMENT before you macro-ize anything in a %DO loop.
Here is my original paper https://support.sas.com/resources/papers/sgf09/318-2009.pdf on using PROC DOCUMENT and ODS DOCUMENT to replay and rearrange ODS output. As you can see, I did not macro-ize any folder/directory/object creation in the new Document store.
For detailed help, I recommend working with Tech Support. They can look at ALL your code and ALL your data and help you come to a resolution in getting the Table of Contents the way you want.
I recommend to my students that they start by making an entirely new (initially empty) document store, then design the folder structure they want and then copy objects one at a time and replay frequently, to make sure that phantom titles, page breaks or bookmarks from the original procedure output are not being accidentally copied into the new document store.
Cynthia
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.