*HTML file;
title 'ods demo 1';
ods html file ='demo.html';
proc print data = sashelp.class(obs=5);run;
ods html close;
*PDF file;
ods pdf file ='demo.pdf' style=SASDocPrinter;
proc print data = sashelp.class(obs=5);run;
ods pdf close;
*RTF file/excel file;
ods rtf file ='demo.rtf' style=SASDocPrinter;
ods html file ='demo.xls';
proc means data = sashelp.class maxdec=2;
var age weight height;
run;
ods html close;
ods rtf close;