The SAS Output Delivery System and reporting techniques

ODS HTML Output

Reply
New Contributor
Posts: 4

ODS HTML Output

I am using the ODS HTML statement to create an EXCEL report with a STYLE of Minimal. I am using TITLE '' to eliminate the SAS SYSTEM header, but how do I eliminate the 2 blank rows at the top of my output EXCEL file?? I want my EXCEL report to open with the column headings in row 1...Any suggestions?? Thanks..
SAS Super FREQ
Posts: 8,742

Re: ODS HTML Output

Hi:
Are you by any chance still running SAS 8? There used to be a problem with the ODS HTML tags that were written that generated some extra blank lines at the top of your HTML file (these blank lines are ignored in the browser, but not in Excel), but I thought that had been fixed in SAS 9.

At any rate, you can try these other methods of creating "plain" HTML files that Excel can open:
[pre]
options nodate nonumber;
title;
ods chtml file='c:\temp\cht.xls';
ods html4 file='c:\temp\ht4.xls' style=minimal;
ods htmlcss file='c:\temp\htcs.xls' style=minimal;

proc print data=sashelp.class;
run;

ods _all_ close;

[/pre]

Note that the CHTML method of creating HTML files does not need a STYLE= option because the "compact" HTML that is generated does not contain any style information.

cynthia
New Contributor
Posts: 4

Re: ODS HTML Output

We are running SAS 9.1.3...........
New Contributor
Posts: 4

Re: ODS HTML Output

Thanks....I will try these options and see what happens...
New Contributor
Posts: 4

Re: ODS HTML Output

Thanks....The ODS CHTML option worked to eliminate the 2 blank rows but now my command, /STYLE={HTMLSTYLE="VND.MS-EXCEL.NUMBERFORMAT:@"}, in my VAR statement is not working. I am using this because I have several large numeric fields which I want to load in the EXCEL file as text and not come over as exponents....Any more ideas?? Thanks for your help....
Ask a Question
Discussion stats
  • 4 replies
  • 170 views
  • 0 likes
  • 2 in conversation