ods rtf file='c:/sample.rtf' bodytitle;
title 'My Sample Title';
footnote 'My Sample Footnote';
proc report data=sashelp.class nowd;
column age height weight;
define age / group;
define height / mean f=8.;
define weight / mean f=8.;
run;
ods rtf close;
-----------------------
如果运行上面语句,会在输出的RTF文档上加上日期和序号作为页眉,要想去除页眉,应该在运行上面语句前加上如下选项:
options nodate NONUMBER;
nodate代表不输出日期
nonumber代表不输出页号
这样就干干净净了,完整程序如下:
options nodate NONUMBER;
ods rtf file='c:/sample.rtf' bodytitle;
title 'My Sample Title';
footnote 'My Sample Footnote';
proc report data=sashelp.class nowd;
column age height weight;
define age / group;
define height / mean f=8.;
define weight / mean f=8.;
run;
ods rtf close;