Hello,
I export a report (via proc report) into excel and I would like to keep a specifiq numerci format.
When I launch this code below, it works. I mean, in excel the number is kept into numeric format
define MNT_MOIS_AMO_AVT_SORTIE / '' style(column)={tagattr='format:000 000 000.00'};
but I create this format named "frmt_num_spac_comma" via proc format .
so I try this
define MNT_MOIS_AMO_AVT_SORTIE / '' style(column)={tagattr=frmt_num_spac_comma.};
but it does not work.
how could I specify the created format ? thanks a lot for your in advance.
Nasser
for exmple the value 225353,74382 I would like to get in excel, a number (and not text) like 225 353,74382 (with space thousand and ',' separator).
but with this below, I get the correct displayed but it is a text
define MNT_MOIS_AMO_AVT_SORTIE / '' f = frmt_num_spac_comma.
And with this below, I get a number but the display is not correct 000 225 353,74000
define MNT_MOIS_AMO_AVT_SORTIE / '' style(column)={tagattr='format:000 000 000.00000'} ;
You can only use formats which are in Excel. Basically Excel takes the text you create and interprets it internally before rendering it, so if it doesn't recognise a format then it doesn't use it. Have a look at the formats in Excel, there are many of them. If that doesn't cover it then you need to create a custom format in Excel and store to normal.dot. Outside the scope of this forum though.
thank you very much.
so I started to create a format within, excel like # ##0,00000'
and then in proc report I do this :
define MNT_MOIS_AMO_AVT_SORTIE / '' style(column)={tagattr='format:# ##0,00000'}
I get a number but I only get 2 decimales instaed of 5
Available on demand!
Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.
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.