Creating Enhanced HTML Output

In the SAS windowing environment, by default, if you have not closed and reopened the ODS HTML destination, HTML output is created. You can specify options in the ODS HTML statement to create frame, contents, page, and body files. In the example below, when you run the program, the body file is displayed in the Results Viewer. To view the body file, contents file, and frame file together as a single HTML page, open the frame file from your local directory.
The PATH= option in the ODS HTML statement specifies the directory, folder, or partitioned data set that you are using to store your files. Once you have specified PATH='your-directory-path' in the ODS HTML statement, the files html-bodyPrdsale.htm, html-contentsPrdsale.htm, and html-framePrdsale.htm are automatically stored in 'your-directory-path'.
options nodate nonumber;
proc sort data=sashelp.prdsale out=prdsale;
    by Country;
run;

ods html path='your-directory-path' body='html-bodyPrdsale.htm'
        contents='html-contentsPrdsale.htm'
        frame='html-framePrdsale.htm';
title 'Actual Product Sales';
title2 '(millions of dollars)';
proc tabulate data=prdsale;   
    class region division prodtype;   
    classlev region division prodtype;   
    var actual;   
    keyword all sum;
    keylabel all='Total';   
    table (region all)*(division all),
         (prodtype all)*(actual*f=dollar10.) /
         misstext=[label='Missing']
         box=[label='Region by Division and Type']; 
run;

title "PROC UNIVARIATE Output";
title2;

ods select ExtremeObs Quantiles Moments;
proc univariate data=prdsale;
    by Country;
    var actual;
run;

title 'Sales Figures for First Quarter by Product';

proc sgpanel data=prdsale;
    where quarter=1;
    panelby product / novarname;
    vbar region / response=predict;
    vline region / response=actual lineattrs=GraphFit;
    colaxis fitpolicy=thin;
    rowaxis label='Sales';
run;
ods html close;
Frame File Created with the ODS HTML Statement Displayed in Internet Explorer
Frame File Created with the ODS HTML Statement Displayed in Internet Explorer