Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

How do I redirect batch output to a file (But still see the output).

Posted on 2011-03-05
2
609 Views
Last Modified: 2012-05-11
I a running a batch fille.
The batch file has some output. So, I want to save the output to a file (Also error messages, also "batch questions").
BUT, I also want to see the output, so I can answer the "batch questions" and also monitor the batch progress.

Thanks zmau
0
Comment
Question by:zmau
2 Comments
 
LVL 69

Accepted Solution

by:
Qlemo earned 250 total points
ID: 35044409
You need a 3rd-party tool called tee. Any implementation will do, for example this one: http://www.softpedia.com/get/System/System-Miscellaneous/Wintee.shtml

Using that, you can do
   batchfile 2>&1 | tee LogFile.txt
Which should redirect errors and any other output to both the screen and the log file.
0
 
LVL 1

Author Closing Comment

by:zmau
ID: 35044429
Thanks
Amazing that windows does not allow this............
0

Featured Post

Flexible connectivity for any environment

The KE6900 series can extend and deploy computers with high definition displays across multiple stations in a variety of applications that suit any environment. Expand computer use to stations across multiple rooms with dynamic access.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7. Start the SARDU utility: Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question