Articles

Solved SET is not displayed in console if cmd log written to text

November 23, 2012 at 05:56:31
Specs: Windows 2003

In the batch file I will be capturing the values from user. I also would like to capture the cmd output as a log.

With the below batch file, the SET statement is written to log and not shown in the CONSOLE.

1.bat
@echo off
IF NOT %1!==/go! %0 /go 1>D:\Scripts\Logs\%~n0_%date:~4,2%%date:~7,2%%date:~10,4%.log 2>&1

start D:\Scripts\CIDBSyncDirCleanUp.bat

:: Replace the versions in the Db Sync config files
set /p BuildVersion="Please type DBversion# to replace in DB Sync files: "


See More: SET is not displayed in console if cmd log written to text

Report •


#1
November 23, 2012 at 17:07:27
✔ Best Answer

Untested, but I'm drunk.
>CON set /p BuildVersion="Please type DBversion# to replace in DB Sync files: "

How To Ask Questions The Smart Way


Report •

#2
December 3, 2012 at 05:28:04

Thank You. It worked..

Report •

Related Solutions


Ask Question