ok, i followed your advice a little bit and tried some things out with proc report.
It is less code, but it is less flexibel. I have some questions to ask.
My Output:
http://img140.imageshack.us/img140/4729/outputv.jpg
My Questions:
1. How can i get the by variable not printed out in between?
2. Why are there spaces before Holdcode (tested with 2 different styles)
3. How does my link gets opened in a new window?
4. Can i add formatting to my text in the compute before part?
My Code:
[pre]
ods html file=_webout style=sasweb;
proc report data=prio_table nowd; /* title 'Testing Outputs'; */
column Facility Lot_id Route Holdcode Holdnote Execby ProcessEngineer BatchEngineer Holdcode;
define Lot_id /group;
define Facility / group;
by Lot_id ;
compute before _page_;
text1 = "Holdcode: " || strip(Holdcode) || " Holdnote: " || strip(Holdnote) || "" ;
text2 = "ProcessEngineer: " || strip(ProcessEngineer) || " BatchEngineer: " || strip(BatchEngineer) || "" ;
line text1 $;
line text2 $;
endcomp;
compute Lot_id ;
urlstring = "http://www.sas.com/";
if Lot_id ne ' ' then
call define (_row_,'STYLE','style={background=orange}');
CALL DEFINE(_COL_, 'URL', urlstring );
CALL DEFINE(_COL_, 'STYLE','style={hreftarget=_blank}' );
endcomp;
compute Execby ;
if Execby eq 'PLINE' then
call define (_row_,'STYLE','style={background=red}');
endcomp;
run;
ods html close;
[/pre]