Solved How to turn off the output of the command before '|' ?

September 29, 2016 at 05:45:19
Specs: Windows 7
@echo off
:on
attrib a.txt|findstr "A"&© a.txt b.txt&attrib -a a.txt
ping 127.1 -n 3 >nul
goto on
pause
===========
Run it and below information appears on screen:
A D:\a.txt
1 file(s) copied.
Now I want to turn off the first line (i.e., only '1 file(s) copied.' appears). What should I do?

See More: How to turn off the output of the command before | ?

Reply ↓  Report •


#1
September 29, 2016 at 06:33:28
Maybe the simple answer, REM?

Reply ↓  Report •

#2
September 29, 2016 at 20:48:25
That's some quirky code. I think I get the gist of a repetitive backup, but I'll wait for more shoes to drop on this one. There's probably a better way to accomplish your objective (xcopy, etc). Lots of ways to log progress or status of backup. Lots of ways to backup.

message edited by nbrane


Reply ↓  Report •

#3
September 30, 2016 at 06:54:27
✔ Best Answer
nbrane: There's probably a better way
ROBOCOPY

How To Ask Questions The Smart Way

message edited by Razor2.3


Reply ↓  Report •

Related Solutions


Ask Question