<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Excel exporting with 2 decimals for all values in ODS and Base Reporting</title>
    <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Excel-exporting-with-2-decimals-for-all-values/m-p/50938#M6494</link>
    <description>Found it...!!!!&lt;BR /&gt;
&lt;BR /&gt;
define	trans_amount / display "Transaction Amount" format=12.2 style(column)={tagattr="format:##0.00" outputwidth=1in };&lt;BR /&gt;
&lt;BR /&gt;
or&lt;BR /&gt;
&lt;BR /&gt;
call define(_col_,'style','style={tagattr="formula:R[-1]C+RC[-2] format:##0.00"}');</description>
    <pubDate>Fri, 15 Apr 2011 12:05:14 GMT</pubDate>
    <dc:creator>SanjayM</dc:creator>
    <dc:date>2011-04-15T12:05:14Z</dc:date>
    <item>
      <title>Excel exporting with 2 decimals for all values</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Excel-exporting-with-2-decimals-for-all-values/m-p/50937#M6493</link>
      <description>I am using the following code to export data into excel.&lt;BR /&gt;
The excel also has formulas added which I have ignored in this example.&lt;BR /&gt;
&lt;BR /&gt;
I need some help in outputting the values consistently with 2 decimals for numeric columns and values. &lt;BR /&gt;
ods listing close;&lt;BR /&gt;
&lt;BR /&gt;
ods tagsets.excelxp file="&amp;amp;rep_filename."&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
			ods tagsets.excelxp file="&amp;amp;rep_filename."&lt;BR /&gt;
				style=styles.printer&lt;BR /&gt;
			      options(embedded_titles='yes' sheet_interval='none' &lt;BR /&gt;
					width_fudge='0.75' sheet_name="&amp;amp;customer_number"&lt;BR /&gt;
			        default_column_width="10,0,8,8,8,8,8,8,8"  FitToPage = 'yes'  PAGES_FITWIDTH = '1' Pages_FitHeight = '100')&lt;BR /&gt;
				;&lt;BR /&gt;
					ods tagsets.excelxp options(embedded_titles='yes' &lt;BR /&gt;
							sheet_interval='none' sheet_name="&amp;amp;customer_number"  FitToPage = 'yes' PAGES_FITWIDTH = '1' Pages_FitHeight = '100');&lt;BR /&gt;
&lt;BR /&gt;
		proc report data=mps18_final;&lt;BR /&gt;
			columns cntrows  trans_eff_date  code description account_number&lt;BR /&gt;
					trans_amount &lt;BR /&gt;
					col_bc &lt;BR /&gt;
					arrears_bal_for; &lt;BR /&gt;
&lt;BR /&gt;
			define cntrows / computed noprint;&lt;BR /&gt;
			define	trans_eff_date		/	display	"Transaction Date" center style(column)={outputwidth=1.2in just=center};&lt;BR /&gt;
			define	code				/	display	"Code" 	center	format=$10. style(column)={outputwidth=0.70in just=center};&lt;BR /&gt;
			define	description			/	display	"Description" format=$100. style(column)={outputwidth=2in};&lt;BR /&gt;
			define	account_number		/	display	"Sub Account Number" center	format=10. style(column)={outputwidth=1in just=center};&lt;BR /&gt;
			define	trans_amount		/	display	"Transaction Amount" format=12.2 style(column)={outputwidth=1in };&lt;BR /&gt;
			define	col_bc				/	display	"Account Balance" format=12.2 style(column)={outputwidth=0.70in};&lt;BR /&gt;
			define arrears_bal_for 		/ 	computed "Arrears Balance" format=12.2 style(column)={outputwidth=0.70in};&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
I have just provided a sample of the code and not the entire code</description>
      <pubDate>Fri, 15 Apr 2011 10:36:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Excel-exporting-with-2-decimals-for-all-values/m-p/50937#M6493</guid>
      <dc:creator>SanjayM</dc:creator>
      <dc:date>2011-04-15T10:36:03Z</dc:date>
    </item>
    <item>
      <title>Re: Excel exporting with 2 decimals for all values</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Excel-exporting-with-2-decimals-for-all-values/m-p/50938#M6494</link>
      <description>Found it...!!!!&lt;BR /&gt;
&lt;BR /&gt;
define	trans_amount / display "Transaction Amount" format=12.2 style(column)={tagattr="format:##0.00" outputwidth=1in };&lt;BR /&gt;
&lt;BR /&gt;
or&lt;BR /&gt;
&lt;BR /&gt;
call define(_col_,'style','style={tagattr="formula:R[-1]C+RC[-2] format:##0.00"}');</description>
      <pubDate>Fri, 15 Apr 2011 12:05:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Excel-exporting-with-2-decimals-for-all-values/m-p/50938#M6494</guid>
      <dc:creator>SanjayM</dc:creator>
      <dc:date>2011-04-15T12:05:14Z</dc:date>
    </item>
  </channel>
</rss>

