BookmarkSubscribeRSS Feed
Filipvdr
Pyrite | Level 9
proc report data=LotWafer_Matrix nowd style(report) = [rules=groups cellspacing=0pt cellpadding=2pt];
columns LOT_ID ChildNr BlockSeq OperationSeq OperSeq OpersAway Block Operation
W01 W02 W03 W04 W05 W06 W07 W08 W09 W10 W11 W12 W13 W14 W15 W16 W17 W18 W19 W20 W21 W22 W23 W24 W25
oWaferMap oWafersToBeProcessed MainStepService;

compute W02;
url_SP = "http://wiksas.imec.be:8080/SASStoredProcess/do?_program=%2FFAB%2Fedoc_lot_attach";
url_stp = compress(url_SP) || "&sel_lotID=" || compress("&sel_lot") || "&Wafer=" || compress(W02) || '" title="View Data" target="_blank';
CALL DEFINE(_COL_, 'URL', url_stp );
if substr(W02,1,1) eq 'D' then call define (_col_,"STYLE","style={BACKGROUND=#99FF33 FONT_WEIGHT=BOLD}");
endcomp;
run;

now i have defined a link to attach, i want an other link, to view..
and i want it in the same cell

possible or not?
1 REPLY 1
Cynthia_sas
SAS Super FREQ
Hi:
Yes, it is possible to get 2 hyperlinks in one cell. If you run the code below (not as a stored process), you will see that clicking the NAME value takes you to www.sas.com and clicking the age value takes you to www.setgame.com.

But your CALL DEFINE statement is setting a single URL for the ENTIRE value of the W02 column. You cannot use CALL DEFINE to set 2 different URLs in 1 column. But, you can set 2 URLs -- just not with CALL DEFINE. I used simple URLs and if you have issues with the URLs working in the context of a stored process, I'd recommend working with Tech Support.

cynthia

[pre]
ods html file='c:\temp\test2url.html' style=sasweb;

title 'Test 2 URLs';
proc report data=sashelp.class nowd
style(column)={protectspecialchars=off};
where age = 13;
column name age dispinfo height weight;
define name / display noprint;
define age / display noprint;
define dispinfo / computed;
define height /sum;
define weight / sum;
compute dispinfo / character length=400;
url1 = '<a href="http://www.sas.com">';
url2 = '<a href="http://www.setgame.com">';
dispinfo = catt('<div>',url1,name,'</a></div>&nbsp;<br/><div>',url2,put(age,2.0),'</a></div>');
endcomp;
run;
ods html close;
[/pre]

sas-innovate-2024.png

Today is the last day to save with the early bird rate! Register today for just $695 - $100 off the standard rate.

 

Plus, 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
  • 672 views
  • 0 likes
  • 2 in conversation