9

37587 - How to eliminate nodes in the PDF, RTF, and HTML table of contents

 3 years ago
source link: http://support.sas.com/kb/37/587.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

Sample 37587: How to eliminate nodes in the PDF, RTF, and HTML table of contents

SAS procedures and the DATA step generate at least two nodes in the table of contents generated by ODS PDF, the CONTENTS= option on the ODS HTML statement, and the CONTENTS TOC_DATA options on the ODS RTF statement. The first node's text can be controlled by the ODS PROCLABEL statement .

The second node can be controlled in some instances by options in the PROC statements or substatements in a PROC statement. The DESCRIPTION= option on the action statement of SAS/GRAPH procedures can be used to change the text entries of the second nodes. See Sample 25248 for an example.

The CONTENTS= option in the PRINT, REPORT, and TABULATE PROC statements can be used to change or eliminate the text of the second node produced by these procedures. See SAS Note 23428 for sample code. In addition, PROC TEMPLATE can be used to make changes to this text for procedures that use a TABLE template.

While changes to the text of the second node are helpful, it is often the case that only one set of nodes is required or needed in the table of contents. For full control of the table of contents nodes, use ODS DOCUMENT to store the results of the PROC or DATA steps, then use PROC DOCUMENT to replay the output with the desired nodes and labels.

The sample code in the Full Code tab generates two PDF files showing a change in the table of contents from:

The PRINT Procedure
  Data Set SASHELP.CLASS
The GPLOT Procedure
  Plot of Age * Name
First Node
Second Node

For additional information regarding the ODS DOCUMENT destination and PROC DOCUMENT, see ODS DOCUMENT resources.


These sample files and code examples are provided by SAS Institute Inc. "as is" without warranty of any kind, either express or implied, including but not limited to the implied warranties of merchantability and fitness for a particular purpose. Recipients acknowledge and agree that SAS Institute shall not be liable for any damages whatsoever arising out of their use of this material. In addition, SAS Institute will provide no support for the materials contained herein.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK