BookmarkSubscribeRSS Feed
Thao
Calcite | Level 5
Does anyone know anyway I can insert a dynamic summary text box into html output file which include several tables (from proc print)?

I am using ODS Html to export the output at the moment.

Thanks in advance.
5 REPLIES 5
JuanS_OCS
Amethyst | Level 16

You have several options ( a very simple one is to use an iframe that will contain your html file created by ODS).

Or best options as ActiveX, javascript, AJAX, etc can make of it a very beautiful product of yours. Also a bit more complex, but not too much.

 

This is a question really related to Web developing, therefore:

If you have any kind of web developer at your place, I would strongly recommend you to contact them, they can make the life really easy to you, as you won't need to invent the wheel again 😉

JuanS_OCS
Amethyst | Level 16

In any case, I would recommend you to move this topic to the ODS group of topics. Probably you will reach the most suitable public for your question

Ksharp
Super User

I am not sure I understand totally your requirement.

 

ods graphics/height=1cm width=2cm;
proc sgplot data=sashelp.class noborder;
scatter x=weight y=height/ markerattrs=(size=0);
inset ("sum"="32" "n"="200") / noborder textattrs=(weight=bold size=20 );
xaxis display=none;
yaxis display=none;
run;
proc print data=sashelp.class;run;

x.png

Thao
Calcite | Level 5

Thank you for your answer.

 

It is quite close to what I want.

 

In your example, instead of hard-code "32" and "200", I want it to be calculated automatically by using the table.

Example:

Max Age is ... from person name ....

I want "..." conducted by codes because I am making a macro and the user will input detail.

 

I think macro variable would help, however these macro variables  are created in file while I need them as global ones in order to put it in to summary text box.

Ksharp
Super User

Yes. you need generate macro variable for these. But that is another question.

 

For the golbal macro variable, you can assign  local macro variable value to golbal  Like:

 

 

%global x ;

 

%yourmacro;

%local y;

.........

%let x=&y;

%mend;

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

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
  • 5 replies
  • 738 views
  • 0 likes
  • 3 in conversation