Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

export to multiple excel tabs 3

Status
Not open for further replies.

aybooth

MIS
Feb 6, 2004
9
US
How can I export from one sas data set to multiple excel tabs on one spreadsheet. I want to segment the dataset using a variable I have created which denotes which department the records belong to.

Thanks

Anthony
 
Strange. No idea how CHTML can pick it up but ExcelXP can't. It must be doing something different.

Chris
Business Analyst, Code Monkey, Data Wrangler.
SAS Guru.
 
Chris,

Yes, they're definitely different.

Here's an example of one output cell using EXCELXP:
Code:
<Cell ss:StyleID="Data" ss:Index="1"><Data ss:Type="Number">012345678</Data></Cell>

Here's the same cell, but out output using CHTML:
Code:
<td>0123456</td>

EXCELXP's output is xml and meta data are embedded in the data tag. This is why I can include the [tt]<STYLE> TD {MSO-NUMBER-FORMAT:\@}</STYLE>[/tt] line in the head, and it's effectively ignored. That's because it's overridden at the cell. CHTML's output is html with no meta data, so the style attribute in the head is not overridden.

There is one item that differentiates numeric strings from numeric numbers: spaces. Here's how CHTML outputs numeric numbers:

Code:
<td align="right">          1</td>

Again, ODS looks to the datasource to determine which column is numeric/string/date and does the spacing on numbers. For dates, it just leaves it as it comes in:

Code:
<td align="right">02/14/2000</td>

So you see, somehow CHTML recognizes the difference between the numeric strings (second example) and numeric numbers (third example). It then treated each slightly differently. Alas, I don't know how to go any deeper in analysis. Feel free to pass this along Vince Delgobbo, or whoever is working on the EXCELXP tagset. Maybe it will provide an avenue to investigate how to simplify the numeric strings problem.

- Larry


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top