Prompt user for file name in a batch file.

January 29, 2011 at 11:55:23
Specs: Windows XP
I need to have current files copied from a server to an external drive. I have the code written, but do not know the code to have the user enter the proper file name (usually the current date). Right now I have to remame the files located in my .bat file in order to get the correct files copied.

See More: Prompt user for file name in a batch file.

Report •


#1
January 29, 2011 at 12:59:53
To prompt the user to enter anything code

set /P myvar=Enter whatever you like^>

The environment variable specified, in the example myvar, will hold what typed.

Report •
Related Solutions


Ask Question