Answer the question
In order to leave comments, you need to log in
How to create a file from bat with current date?
Tried like this: echo . > "C:\Folder Name\log%DATATIME%.txt"
and like this:
echo . > "C:\Folder Name\log" + %DATATIME% + ".txt"
echo . > "C:\Folder Name\log"%DATATIME%".txt"
Answer the question
In order to leave comments, you need to log in
echo . > "C:\FolderName\log-%date:~6,4%-%date:~3,2%-%date:~0,2%.txt"
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question