<?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 Retain Leading zeros in ODS and Base Reporting</title>
    <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Retain-Leading-zeros/m-p/5789#M2346</link>
    <description>I have the following code:&lt;BR /&gt;
ods html file='N:\admin\Linda\SAS\TESTCounties.xls' style=minimal;&lt;BR /&gt;
proc print data=Linda.AssocCnty label;&lt;BR /&gt;
var CL_N CL_Nm REGION AssocNumeric;&lt;BR /&gt;
label CL_N ='CL N'&lt;BR /&gt;
CL_Nm = 'CL Nm';&lt;BR /&gt;
&lt;BR /&gt;
run;&lt;BR /&gt;
ods _all_ close;&lt;BR /&gt;
ods listing;&lt;BR /&gt;
&lt;BR /&gt;
I would like to retain leading zeros.&lt;BR /&gt;
I found the following on this site but do not know where to put it.&lt;BR /&gt;
I've retained leading zeroes for Excel output via ODS HTML using&lt;BR /&gt;
&lt;BR /&gt;
... htmlstyle='vnd.ms-excel.numberformat:@' ...&lt;BR /&gt;
&lt;BR /&gt;
Can someone please tell me where to put it in the above code.  If not there - where??</description>
    <pubDate>Tue, 04 Dec 2007 20:23:17 GMT</pubDate>
    <dc:creator>lloraine</dc:creator>
    <dc:date>2007-12-04T20:23:17Z</dc:date>
    <item>
      <title>Retain Leading zeros</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Retain-Leading-zeros/m-p/5789#M2346</link>
      <description>I have the following code:&lt;BR /&gt;
ods html file='N:\admin\Linda\SAS\TESTCounties.xls' style=minimal;&lt;BR /&gt;
proc print data=Linda.AssocCnty label;&lt;BR /&gt;
var CL_N CL_Nm REGION AssocNumeric;&lt;BR /&gt;
label CL_N ='CL N'&lt;BR /&gt;
CL_Nm = 'CL Nm';&lt;BR /&gt;
&lt;BR /&gt;
run;&lt;BR /&gt;
ods _all_ close;&lt;BR /&gt;
ods listing;&lt;BR /&gt;
&lt;BR /&gt;
I would like to retain leading zeros.&lt;BR /&gt;
I found the following on this site but do not know where to put it.&lt;BR /&gt;
I've retained leading zeroes for Excel output via ODS HTML using&lt;BR /&gt;
&lt;BR /&gt;
... htmlstyle='vnd.ms-excel.numberformat:@' ...&lt;BR /&gt;
&lt;BR /&gt;
Can someone please tell me where to put it in the above code.  If not there - where??</description>
      <pubDate>Tue, 04 Dec 2007 20:23:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Retain-Leading-zeros/m-p/5789#M2346</guid>
      <dc:creator>lloraine</dc:creator>
      <dc:date>2007-12-04T20:23:17Z</dc:date>
    </item>
    <item>
      <title>Re: Retain Leading zeros</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Retain-Leading-zeros/m-p/5790#M2347</link>
      <description>Hi:&lt;BR /&gt;
  Let's say that your variable CL_N is what you want with leading zeroes, then you would have 2 VAR statements:&lt;BR /&gt;
&lt;BR /&gt;
[pre]&lt;BR /&gt;
var CL_N  / style(data)={htmlstyle="....."};&lt;BR /&gt;
var CL_Nm REGION AssocNumeric;&lt;BR /&gt;
[/pre]&lt;BR /&gt;
&lt;BR /&gt;
The STYLE(DATA) override option allows ODS to pass the HTML style for CL_N (only) into the HTML that's being generated for the output file. The other VAR statement just lists the rest of the variables you want on the report. &lt;BR /&gt;
 &lt;BR /&gt;
cynthia</description>
      <pubDate>Wed, 05 Dec 2007 00:29:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Retain-Leading-zeros/m-p/5790#M2347</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2007-12-05T00:29:17Z</dc:date>
    </item>
  </channel>
</rss>

