Producing HTML Output |
The ODS HTML Statement |
To create HTML output, you open the HTML destination using
the ODS HTML statement. You can specify up to four HTML
files to write to (body files, tables of
contents, page descriptions, and
frames). The specifications for these files can be
|
General form, ODS HTML statement:
ODS HTML where
|
The illustration below shows how a frame file integrates the table of contents and body files. (Page files are not covered in this lesson.) |
Example: Creating a Body
File
First, let's look at an ODS HTML statement that creates only a body file. Later, we'll see how to create a table of contents and a frame.
Using a simple version of the ODS HTML statement, the program below creates
PROC PRINT output in an HTML file. The BODY= option specifies the file
ods html body='f:\admit.html'; proc print data=clinic.admit label; var sex age height weight actlevel; label actlevel='Activity Level'; run; ods html close; Notice the final ODS HTML statement in the program, which closes the HTML destination. This statement follows the RUN statement for the procedure. Let's see what the HTML results look like. |
Copyright © 2002 SAS Institute Inc.,
Cary, NC, USA. All rights reserved.