<?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: Tabulate, Tagsets.ExcelXp and Dates in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92498#M257478</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I posted an example in the OP.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Jan 2014 20:40:52 GMT</pubDate>
    <dc:creator>wcpatton</dc:creator>
    <dc:date>2014-01-15T20:40:52Z</dc:date>
    <item>
      <title>Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92491#M257471</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have example code below.&amp;nbsp; What I'm trying to do is get DATE in my output spreadsheet that Excel actually sees as a date, rather than a text field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ods listing;&lt;/P&gt;&lt;P&gt;options missing = 0;&lt;/P&gt;&lt;P&gt;ods tagsets.excelxp&lt;/P&gt;&lt;P&gt;file= "C:\Sheet3.xml"&lt;/P&gt;&lt;P&gt;&amp;nbsp; style=normal;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc tabulate data=sashelp.stocks missing;&lt;/P&gt;&lt;P&gt;class stock date/style=data_date9;&lt;/P&gt;&lt;P&gt;var high low;&lt;/P&gt;&lt;P&gt;tables (high low),date=''&lt;/P&gt;&lt;P&gt;/row = float;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;ODS TAGSETS.EXCELXP CLOSE;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[ETA: SAS 9.3, Windows XP, Excel 2010]&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Sep 2013 20:17:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92491#M257471</guid>
      <dc:creator>wcpatton</dc:creator>
      <dc:date>2013-09-24T20:17:24Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92492#M257472</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm not actually sure how to do the headers in PROC TABULATE.&amp;nbsp; Using TAGATTR you can tell Excel to treat a number like a date, but that doesn't seem to take effect in headers for some reason I'm not entirely sure of.&amp;nbsp; You could output the tabulate to a dataset and then PROC REPORT that out, that should work at least.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Sep 2013 21:43:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92492#M257472</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2013-09-24T21:43:43Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92493#M257473</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So far, my options have been to either output the date as a number for excel to read (you have to add something, like 21000 to it), or to use a picture format and output it as text and then excel won't recognize it as a date, but at least it will look like one.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Sep 2013 13:28:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92493#M257473</guid>
      <dc:creator>wcpatton</dc:creator>
      <dc:date>2013-09-26T13:28:16Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92494#M257474</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For me it actually will appear as as date with any normal date format, and when excel sees it, it looks like I ask it to - but as text.&amp;nbsp; However if you click in the cell and hit enter, it turns it into an excel date.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Sep 2013 14:38:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92494#M257474</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2013-09-26T14:38:11Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92495#M257475</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No, I'm with you there.&amp;nbsp; The problem is that if I want to use excel formulas or graphs or anything that wants it to be a date, that doesn't work.&amp;nbsp; I can make a formula in excel that dissects the text..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Sep 2013 14:41:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92495#M257475</guid>
      <dc:creator>wcpatton</dc:creator>
      <dc:date>2013-09-26T14:41:04Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92496#M257476</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Bumping because I still have this issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 18:46:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92496#M257476</guid>
      <dc:creator>wcpatton</dc:creator>
      <dc:date>2014-01-15T18:46:30Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92497#M257477</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The tagattr option should fix that. Please, post the code you've tried.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is a great reference for Tagsets to help resolve issues:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sas.com/events/cm/867226/ExcelXPPaperIndex.pdf" title="http://www.sas.com/events/cm/867226/ExcelXPPaperIndex.pdf"&gt;http://www.sas.com/events/cm/867226/ExcelXPPaperIndex.pdf&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 20:39:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92497#M257477</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2014-01-15T20:39:49Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92498#M257478</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I posted an example in the OP.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 20:40:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92498#M257478</guid>
      <dc:creator>wcpatton</dc:creator>
      <dc:date>2014-01-15T20:40:52Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92499#M257479</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Repost in the ODS section, I don't think Cynthia monitors this section and she's probably the one who will have the definitive answer. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 20:56:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92499#M257479</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2014-01-15T20:56:49Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92500#M257480</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm fairly sure there is no good answer, short of modifying the template or some other hack - it's an oddity in how excel works relating to the open xml format.&amp;nbsp; ODS EXCEL may fix this, once I can get my hands on a copy of 9.4 TS1M1 I will confirm (probably not for a few weeks), but that obviously doesn't help a 9.3 user.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 21:00:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92500#M257480</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2014-01-15T21:00:56Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92501#M257481</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A __default_attr="9692" __jive_macro_name="thread" class="jive_macro jive_macro_thread" href="https://communities.sas.com/"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;you can use tagattr, but mine says' the file is corrupt so doing something wrong....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 21:14:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92501#M257481</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2014-01-15T21:14:02Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92502#M257482</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Same here, I get the TABLE error when I use Tagattr.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 21:15:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92502#M257482</guid>
      <dc:creator>wcpatton</dc:creator>
      <dc:date>2014-01-15T21:15:26Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92503#M257483</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I don't think so.&amp;nbsp; See my first response.&amp;nbsp; I don't have the code I used to reverify this when this was originally posted, but from what I recall, Excel won't display the date properly until the cell is selected and validated (hit enter).&amp;nbsp; This was the case for me a year or two ago when I first hit this issue, and I verified it back when this question was originally posted.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 21:17:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92503#M257483</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2014-01-15T21:17:19Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92504#M257484</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hmm, or maybe not.&amp;nbsp; Does this work the way you want it to?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;edit: I think this is sort-of-working, but the format still changes when you select the cell and hit 'enter' - but at least it's closer.&amp;nbsp; Not sure if this is the 'does not work' I remember earlier or if this is an improvement.&lt;/P&gt;&lt;P&gt;IE, if you go to cell D1, select, hit enter, it goes from "02SEP86" to "2-Sep-86".&amp;nbsp; But, at least it's a real date value you can do math on and such.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc template;&lt;/P&gt;&lt;P&gt;define style test;&lt;/P&gt;&lt;P&gt;parent=styles.normal;&lt;/P&gt;&lt;P&gt;class date/&lt;/P&gt;&lt;P&gt;&amp;nbsp; tagattr="m/d/yyyy";&lt;/P&gt;&lt;P&gt;end;&lt;/P&gt;&lt;P&gt;quit;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;ods listing;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;options missing = 0;&lt;/P&gt;&lt;P&gt;ods tagsets.excelxp&lt;/P&gt;&lt;P&gt;file= "C:\temp\test.xml"&lt;/P&gt;&lt;P&gt;&amp;nbsp; style=test;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc tabulate data=sashelp.stocks missing;&lt;/P&gt;&lt;P&gt;class stock date/style=data_date9;&lt;/P&gt;&lt;P&gt;var high low;&lt;/P&gt;&lt;P&gt;tables (high low),date=''*{style=date}&lt;/P&gt;&lt;P&gt;/row = float;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;ODS TAGSETS.EXCELXP CLOSE;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 21:23:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92504#M257484</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2014-01-15T21:23:45Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92505#M257485</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Almost.&amp;nbsp; The Vars are coming out as date style now, as well.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 21:37:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92505#M257485</guid>
      <dc:creator>wcpatton</dc:creator>
      <dc:date>2014-01-15T21:37:32Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92506#M257486</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm not convinced it's working, in any event; looking at the raw XML, it's still a string - excel's just being smart about it.&amp;nbsp; I am probably not using the style properly, I am a PROC REPORT guy not a PROC TABULATE guy when it comes to these sorts of things.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Jan 2014 22:44:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92506#M257486</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2014-01-15T22:44:30Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92507#M257487</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yeah, I'm a tabulate guy, but SAS doesn't seem to want to play nice here.&amp;nbsp; Maybe I'll have to learn REPORT for this, unless SAS wants to fix this.&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jan 2014 13:46:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92507#M257487</guid>
      <dc:creator>wcpatton</dc:creator>
      <dc:date>2014-01-16T13:46:00Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate, Tagsets.ExcelXp and Dates</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92508#M257488</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I believe that the problem is, at least for Tabulate, that the headers are technically always character - so in creating the resulting xml, they're sent as 'string'.&amp;nbsp; You might be able to fix this by editing the tagset itself, though I'm not sure where I'd suggest beginning there.&amp;nbsp; I don't think tagsets.excelxp will receive too much more development now that ODS EXCEL is largely out, so I wouldn't expect it to change - but who knows.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jan 2014 20:39:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Tabulate-Tagsets-ExcelXp-and-Dates/m-p/92508#M257488</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2014-01-16T20:39:11Z</dc:date>
    </item>
  </channel>
</rss>

