<?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: Adding date to a filename in Operating System - Microsoft</title>
    <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156686#M3662</link>
    <description>Use the %time% variable along with the formatting options from above.&lt;BR /&gt;&lt;BR /&gt;Jon</description>
    <pubDate>Thu, 28 Feb 2008 21:07:25 GMT</pubDate>
    <dc:creator>Jon Finley</dc:creator>
    <dc:date>2008-02-28T21:07:25Z</dc:date>
    <item>
      <title>Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156677#M3653</link>
      <description>In DOS, how do you make a copy of a file and add the current date to the filename?  Something like this....&lt;BR /&gt;&lt;BR /&gt;copy file.bat file.&lt;DATE&gt;.bat&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;/DATE&gt;</description>
      <pubDate>Mon, 05 Jan 2004 18:27:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156677#M3653</guid>
      <dc:creator>TheJuiceman</dc:creator>
      <dc:date>2004-01-05T18:27:29Z</dc:date>
    </item>
    <item>
      <title>Re: Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156678#M3654</link>
      <description>Can't be done using built-in tools...&lt;BR /&gt;&lt;BR /&gt;Try using the XSET utility from &lt;A href="http://xset.tripod.com" target="_blank"&gt;http://xset.tripod.com&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;rem DATEFILE.bat&lt;BR /&gt;rem Makes a Text File with the Current Date as the Name&lt;BR /&gt;&lt;BR /&gt;C:\BATCH\DOS\XSET CUR-DATE DATE YY-MM-DD&lt;BR /&gt;REM &amp;gt; %CUR-DATE%.TXT&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;This will make a zero-byte file which name will be in the format &lt;BR /&gt;of "Year-Month-Day". That keeps similar files in chronological order. &lt;BR /&gt;You may then load it into an editor and add text.&lt;BR /&gt;&lt;BR /&gt;Jon</description>
      <pubDate>Mon, 05 Jan 2004 23:57:50 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156678#M3654</guid>
      <dc:creator>Jon Finley</dc:creator>
      <dc:date>2004-01-05T23:57:50Z</dc:date>
    </item>
    <item>
      <title>Re: Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156679#M3655</link>
      <description>Hello &lt;BR /&gt;&lt;BR /&gt;Following will work&lt;BR /&gt;set dd=%date:~0,2%&lt;BR /&gt;set mm=%date:~3,2%&lt;BR /&gt;set yy=%date:~6,4%&lt;BR /&gt;copy file.bat file.%dd%%mm%%yy%.bat&lt;BR /&gt;&lt;BR /&gt;Sanjay Suri</description>
      <pubDate>Tue, 06 Jan 2004 00:22:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156679#M3655</guid>
      <dc:creator>Sanjay Kumar Suri</dc:creator>
      <dc:date>2004-01-06T00:22:26Z</dc:date>
    </item>
    <item>
      <title>Re: Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156680#M3656</link>
      <description>Without set following command is also working.&lt;BR /&gt;&lt;BR /&gt;copy file.bat file.%date:~0,2%%date:~3,2%%date:~6,4%.bat&lt;BR /&gt;&lt;BR /&gt;Thanks.&lt;BR /&gt;&lt;BR /&gt;sks</description>
      <pubDate>Tue, 06 Jan 2004 02:01:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156680#M3656</guid>
      <dc:creator>Sanjay Kumar Suri</dc:creator>
      <dc:date>2004-01-06T02:01:13Z</dc:date>
    </item>
    <item>
      <title>Re: Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156681#M3657</link>
      <description>You tried this in DOS?&lt;BR /&gt;&lt;BR /&gt;Not the NT/2000/XP command prompt, but under Win 98/95 (7.0) DOS or 6.22 MS-DOS?&lt;BR /&gt;&lt;BR /&gt;Jon</description>
      <pubDate>Tue, 06 Jan 2004 02:18:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156681#M3657</guid>
      <dc:creator>Jon Finley</dc:creator>
      <dc:date>2004-01-06T02:18:53Z</dc:date>
    </item>
    <item>
      <title>Re: Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156682#M3658</link>
      <description>Bobby...  maybe I'm miss-reading your question.  I understood you to ask how to do it under DOS.  If you're asking how to do this within the CMD prompt of NT/2000/XP, then Sanjay has answered your question.  In addition, there are several other postings in the MS forums across the last 2 years that discribe various other ways of creating a filename timestamp under NT/2000/XP.&lt;BR /&gt;&lt;BR /&gt;Let us know what DOS version or OS you REALLY want to work this in.&lt;BR /&gt;&lt;BR /&gt;Jon</description>
      <pubDate>Tue, 06 Jan 2004 02:24:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156682#M3658</guid>
      <dc:creator>Jon Finley</dc:creator>
      <dc:date>2004-01-06T02:24:44Z</dc:date>
    </item>
    <item>
      <title>Re: Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156683#M3659</link>
      <description>Thanks everyone for the responses.  What Sanjay suggested worked PERFECTLY!!!  Thanks again for all of the help, guys!!!  This forum is incredible!!!</description>
      <pubDate>Tue, 06 Jan 2004 19:14:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156683#M3659</guid>
      <dc:creator>TheJuiceman</dc:creator>
      <dc:date>2004-01-06T19:14:35Z</dc:date>
    </item>
    <item>
      <title>Re: Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156684#M3660</link>
      <description>Hello Bobby&lt;BR /&gt;&lt;BR /&gt;I am glad my solution worked for you.&lt;BR /&gt;Apart from appreciation, your libral allocation of points to my answer will help me inch towards my first cap.&lt;BR /&gt;&lt;BR /&gt;Thanks.&lt;BR /&gt;&lt;BR /&gt;sks</description>
      <pubDate>Thu, 08 Jan 2004 00:04:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156684#M3660</guid>
      <dc:creator>Sanjay Kumar Suri</dc:creator>
      <dc:date>2004-01-08T00:04:22Z</dc:date>
    </item>
    <item>
      <title>Re: Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156685#M3661</link>
      <description>what if i also want to hour minute information in my filename like :file28022008114501&lt;BR /&gt;(fileddmmyyyyhh24miss)&lt;BR /&gt;any help would be appreciated</description>
      <pubDate>Thu, 28 Feb 2008 09:50:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156685#M3661</guid>
      <dc:creator>Melis Bilsel</dc:creator>
      <dc:date>2008-02-28T09:50:52Z</dc:date>
    </item>
    <item>
      <title>Re: Adding date to a filename</title>
      <link>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156686#M3662</link>
      <description>Use the %time% variable along with the formatting options from above.&lt;BR /&gt;&lt;BR /&gt;Jon</description>
      <pubDate>Thu, 28 Feb 2008 21:07:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-microsoft/adding-date-to-a-filename/m-p/3156686#M3662</guid>
      <dc:creator>Jon Finley</dc:creator>
      <dc:date>2008-02-28T21:07:25Z</dc:date>
    </item>
  </channel>
</rss>

