BookmarkSubscribeRSS Feed
Bdjordan
Calcite | Level 5
Is it possible to set up bookmarks while creating the rtf using the out2rtf macro? If so do you have any examples?
1 REPLY 1
Cynthia_sas
SAS Super FREQ
Hi:
It looks like %OUT2RTF was written in 1999 and last updated in 2002. I suspect that most of the folks who used to use %OUT2RTF (which takes your LISTING output and converts it to RTF form) have mostly switched to ODS RTF.

My guess is that to accomplish what you want
1) you would have to know the RTF to create bookmarks (for a Table of Contents?)
2) you would have to modify the %OUT2RTF program code (and test it, etc) -- I don't know of any examples that show using a modified version of %OUT2RTF

You might be able to use techniques similar to the ones in this paper
http://www.lexjansen.com/pharmasug/2006/technicaltechniques/tt15.pdf in order to insert bookmarks or you might be able to insert bookmarks by post-processing the RTF file -- after you use the %OUT2RTF. Just a warning -- RTF is very picky about every { } and \ in the RTF file -- if you to down this road, but generate mis-matched control characters, Word will not display the RTF file.

On the other hand, if you were able to switch to ODS RTF techniques, this paper shows how to insert hyperlinks and bookmarks using ODS RTF:
http://www.lexjansen.com/pharmasug/2006/technicaltechniques/tt21.pdf

In addition, ODS RTF supports the CONTENTS= option, which inserts a TOC page into your output and ODS supports the URL= style attribute which allows you to make hyperlinks for table cells. Depending on what you want/need to do, you may have more options with ODS RTF.

cynthia

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

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
  • 950 views
  • 0 likes
  • 2 in conversation