BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hi,

I'm creating an Excel sheet using the ODS tagsets.ExcelXP.

But two things just won't work....

First the alignment of cells. Example:
[PRE]
PROC REPORT DATA=sashelp.class ;
COLUMN _ALL_ ;
DEFINE sex /STYLE(COLUMN)=[just=center] ;
RUN ;
[/PRE]
The style element "just=center" does nothing in the Excel sheet.

Second the wrapping of cells. It's standard with the column headers but not within a table.

Can anyone help me with this?

Thnx,
Thierry
3 REPLIES 3
Eric_SAS
SAS Employee
Which version of the Excelxp tagset are you using?

It should say in the log. If it doesn't say, then it is very old.

You can get the latest tagset here.

http://support.sas.com/rnd/base/ods/odsmarkup/
Cynthia_sas
SAS Super FREQ
Hi:
When I run this code:
[pre]
ods tagsets.excelxp file='c:\temp\try_cntr.xls'
style=sasweb
options(absolute_column_width="20,15,15" doc="Help");

proc report data=sashelp.class nowd
style(column)={just=center};
column name age height;
run;

ods tagsets.excelxp close;

[/pre]

I do see centering (in Excel 2007). Sometimes, you have to make the columns "bigger" in order to see the impact of centering.
I am running the version of the ExcelXP tagset template dated:
[pre]
NOTE: This is the Excel XP tagset (SAS 9.1.3, v1.75, 07/26/07). Add options
(doc='help') to the ods statement for more information.

[/pre]

(from my SAS log)
cynthia
deleted_user
Not applicable
Hi,

Thanks for your reply.

When I run Cynthia's code the centering doesn't work.
I guess it's because the old version of the tagsets I'm using.

I'm using the version:
[pre]
NOTE: This is the Excel XP tagset (SAS 9.1.3, v1.28, 08/29/05). Add options(doc='help') to the ods statement for more information.
[/pre]
I'll update the Tagset and try again.

The wrapping of cells? Is there an option for?

Thanks!
Thierry Message was edited by: TH

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 2419 views
  • 0 likes
  • 3 in conversation