Uses the standard SASHELP.PRDSALE table containing sales data.
1 Code Block
ODS
Explanation : Initialization of the ODS HTML destination with specification of target files for the frameset structure.
Copied!
ods html body='c:\body.html'
contents='c:\contents.html'
page='c:\page.html'
frame='c:\frame.html' ;
1
ods html body='c:\body.html'
2
contents='c:\contents.html'
3
page='c:\page.html'
4
frame='c:\frame.html' ;
2 Code Block
PROC SORT Data
Explanation : Attempt to sort data by country and region. Note: Without the 'OUT=' option, this procedure attempts to modify the source table, which will cause an error if SASHELP is read-only.
Copied!
proc sort data=sashelp.prdsale ;
by country region ;
1
2
PROC SORT
3
DATA=sashelp.prdsale ;
4
BY country region ;
5
3 Code Block
PROC PRINT
Explanation : Display of (theoretically sorted) data grouped by country and region in the HTML report.
Copied!
proc print data=sashelp.prdsale ;
by country region ;
run ;
1
2
PROC PRINT
3
DATA=sashelp.prdsale ;
4
BY country region ;
5
RUN ;
6
4 Code Block
ODS
Explanation : Closing the ODS HTML destination to finalize file writing. The 'dm' command attempts to open the internal browser (specific to the classic Windows interface).
Copied!
ods html close ;
dm "wbrowse 'c:\frame.html'" ;
1
ods html close ;
2
dm "wbrowse 'c:\frame.html'" ;
This material is provided "as is" by We Are Cas. There are no warranties, expressed or implied, as to merchantability or fitness for a particular purpose regarding the materials or code contained herein. We Are Cas is not responsible for errors in this material as it now exists or will exist, nor does We Are Cas provide technical support for it.
SAS and all other SAS Institute Inc. product or service names are registered trademarks or trademarks of SAS Institute Inc. in the USA and other countries. ® indicates USA registration. WeAreCAS is an independent community site and is not affiliated with SAS Institute Inc.
This site uses technical and analytical cookies to improve your experience.
Read more.