Page 2 of 2 FirstFirst 12
Results 16 to 18 of 18

Thread: Date/Time stamp

  1. #16
    Join Date
    Mar 2006
    Posts
    127
    Thanks for the help.

  2. #17
    Join Date
    Mar 2006
    Posts
    127
    That is what I did. Except I used the different script for date/time stamp.

    set dttm=%~t1
    for /F "tokens=1-6 delims=/: " %%i in ("%dttm%") do (

    set date=%%k%%i%%j%%l%%m
    )

    the date/time is displayed as 200701120525PM

    The only issue I have with it is that I want to display the time in a military format. How do I do that?

  3. #18
    Join Date
    Sep 2002
    Location
    Fantasy
    Posts
    4,254
    echo %date:~10,4%%date:~7,2%%date:~4,2%%time:~0,2%%time :~3,2%%time:~6,2%

    result
    20071601150650

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •