BookmarkSubscribeRSS Feed
gzr2mz39
Quartz | Level 8
When the user clicks on "Click here for updates" I would like a new window to open up to www.sas.com.
The table looks correct, however, no link is being created.
Thank you.

data _null_;
dcl odsout obj();
obj.table_start(name: "Stock",
overrides: "width=80pct");
obj.row_start();
obj.format_cell(data: "News",
column_span: 2,
overrides: "backgroundcolor=BIGB color=white font_size=14pt font_weight=bold");
obj.row_end();
obj.row_start();
obj.format_cell(data: "Data released",
overrides: "just=left font_weight=bold color=GRB");
obj.format_cell(data: "5/07/2010",
overrides: "just=left font_weight=bold color=black");
obj.row_end();
obj.row_start();
obj.format_cell(data: "Planned data release date",
overrides: "just=left font_weight=bold color=GRB");
obj.format_cell(data: "6/07/2010",
overrides: "just=left font_weight=bold color=black");
obj.row_end();
obj.row_start();
obj.format_cell(data: "Click here for Updates",
file: "http://www.sas.com",
overrides: "just=left font_weight=bold color=GRB");
obj.format_cell(data: "6/07/2010",
overrides: "just=left font_weight=bold color=black");
obj.row_end();
run;
1 REPLY 1
Cynthia_sas
SAS Super FREQ
Hi:
Well, if you were doing the report in PROC REPORT, the style override would be:
[pre]
style(header)={url='http://www.sas.com' foreground=purple background=pink}
[/pre]

However, I'm not sure that URL= will work with these data step objects, though. If you CAN use FILE: as the right argument, for setting a cell URL, I'm not sure that it will work with the FORMAT_CELL method.

You might also want to check in the pre-production documentation. The pre-production documentation is here:
http://support.sas.com/rnd/base/datastep/dsobject/Power_to_show_documentation.pdf

In the documentation, I also note that there is an OBJECT.HREF method as shown here:
[pre]
obj.href(data: “SAS Home page”,
file: “http://www.sas.com/index.html”);
[/pre]

So, it seems like your FILE: might be OK if you used a different method than OBJ.FORMAT_CELL

Since the ODS DATA step object is still pre-production, you might want to check with Tech Support on this question. If they don't know the answer, they can work with the developers to get you the answer.

cynthia

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
  • 1 reply
  • 1052 views
  • 0 likes
  • 2 in conversation