BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
DmytroYermak
Lapis Lazuli | Level 10

Hi all,

 

Could you please help with the table reporting that should contain links on the correspondent files. I have a dataset that with tables names and should receive a one column with the names and each name should be an interactive.

 

It has to be an rtf and pdf documents. Is it possible with SAS?

  

data test;
  format TABLE $6. LINK $25.;
  input TABLE LINK;
  datelines;
Table1 C:\ProjectX\Table1.rtf
Table2 C:\ProjectX\Table2.rtf
Table3 C:\ProjectX\Table3.rtf
;
run;

 

Thank you!

 

1 ACCEPTED SOLUTION

Accepted Solutions
BrunoMueller
SAS Super FREQ

You can use Proc REPORT with the CALL DEFINE and the URL attribute to set your link. See sample code below.

 

Also have a look at http://support.sas.com/kb/24/182.html concerning the color around the link

 

data test;
  format TABLE $6. LINK $25.;
  input TABLE LINK;
  datalines;
Table1 C:\ProjectX\Table1.rtf
Table2 C:\ProjectX\Table2.rtf
Table3 C:\ProjectX\Table3.rtf
;
run;

ods pdf file="c:\temp\sample.pdf";
proc report data=test;
  column table link _dummy;
  define table / display;
  define link / display noprint;
  define _dummy / computed noprint;
  compute _dummy;
    call define ("table", "URL", link);
/*    call define("table", "style", "style={LINKCOLOR=white}");*/
  endcomp;
run;
ods pdf close;

View solution in original post

2 REPLIES 2
BrunoMueller
SAS Super FREQ

You can use Proc REPORT with the CALL DEFINE and the URL attribute to set your link. See sample code below.

 

Also have a look at http://support.sas.com/kb/24/182.html concerning the color around the link

 

data test;
  format TABLE $6. LINK $25.;
  input TABLE LINK;
  datalines;
Table1 C:\ProjectX\Table1.rtf
Table2 C:\ProjectX\Table2.rtf
Table3 C:\ProjectX\Table3.rtf
;
run;

ods pdf file="c:\temp\sample.pdf";
proc report data=test;
  column table link _dummy;
  define table / display;
  define link / display noprint;
  define _dummy / computed noprint;
  compute _dummy;
    call define ("table", "URL", link);
/*    call define("table", "style", "style={LINKCOLOR=white}");*/
  endcomp;
run;
ods pdf close;
DmytroYermak
Lapis Lazuli | Level 10
Thank you, Bruno! It has worked.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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