Microsoft
Software
Hardware
Network
Question : Windows Batch - Find Day of Week
Hi,
I have the below batch script to create the 'DOW' variable. However when I run it, it's choking on the 4th lineon the 'Command' part. Not sure what is wrong. Any help? Prefer to keep this Windows Batch. Running on Win Server 2003 R2.
REM Set the Day of Week (DOW) Variable
:: setDOW.bat
@echo off
Echo.|Command /C Date>DOW
set /p today=<DOW
set DOW=%today:~16,3%
echo DOW=%DOW%
:: DONE
Answer : Windows Batch - Find Day of Week
In a BAT file, this is all you should need:
@echo off
for /F "tokens=1" %%A in ("%DATE%") do set DOW=%%A
~bp
Random Solutions
Php SOAP-ERROR: Parsing WSDL
Flex Drag and Drop
PHP string replace question
SQL Problem
Access 2007, form datasheet view, change display property of an element based on another element in the record
Return a Char at position
return double array in Delphi call to c++
Issue with Thecus 1u4500 not booting
Microsoft Information Store stalling issues
Auto file move and rename