BookmarkSubscribeRSS Feed
SachinRuk
Calcite | Level 5
Hi all,

I have about 15 graphs in one html file. What I want to do is have a list of names of those graphs and be able to instantly scroll down to those graphs. Rob allison had done something similar with linking to other websites:
http://robslink.com/SAS/democd23/overlib.htm
http://robslink.com/SAS/democd23/overlib_info.htm

but what about linking to graphs within the same file?

Thanks in advance,
Sachin
2 REPLIES 2
Cynthia_sas
Diamond | Level 26
Hi:
Have you looked at FRAME=, BODY= and CONTENTS= options with ODS HTML -- that would make links that pointed to ALL the output created within 1 ODS HTML step. Something similar to this:
[pre]
ods html path='' (url=none)
body='body.html'
contents='toc.html'
frame='frm.html' style=sasweb;
... one step or more than one step ...

ods html close;
[/pre]

Then, if you open the FRM.HTML file, you should see links to all the output that was created, so whether you had 1 step or 20 steps in your ODS HTML "sandwich" there would be a navigation link on the left side that would contain a clickable link to a named anchor that would display on the right-hand side of the frame when you clicked on the link. Even if you use the NEWFILE= option, the FRAME= and CONTENTS= links will contain the correct pointers.

cynthia
GraphGuy
Meteorite | Level 14
To link to graphs in the same html file/webpage, you can use html 'anchors'.

Here is an example...

http://robslink.com/SAS/democd23/anchor.htm
http://robslink.com/SAS/democd23/anchor_info.htm

In this case, each bar in the bar chart drills-down to an html anchor for that state-map lower in the same webpage. Similarly, you could use a table/list instead of a bar chart.
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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 1196 views
  • 0 likes
  • 3 in conversation