An Easier Way to Automatically Name Log Files

Use standard NT DOS functions to automatically name log files with the current date and time.

Readers

January 26, 2003

1 Min Read
ITPro Today logo


In Reader to Reader: "Automatically Name Log Files with the Current Date and Time" (February 2002, InstantDoc ID 23468), Bret Bennett presents a script that uses ntdate.exe to automatically name log files. I have a simpler method that uses the standard Windows NT DOS date and time functions. Listing 1 shows my script.

—George Christie
[email protected]

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like