Link to home
Start Free TrialLog in
Avatar of grg99
grg99

asked on

Fancy use of "Start" command..

I need to start a program running at low priority, so I'm using the "start" command.

Not hard, just type:  start /low    command

EXCEPT, I need to pass some parameters that have spaces in them.


Not Tooooo hard:    start /low  cmd "param one"

EXCEPT, I want to redirect the output of "cmd" to a file.

Not Tooooooo hard, you think:    start /low  cmd "param one"  >Log.txt

NOPE!     ">Log.Txt" is swallowed up by "start", so output from "start" goes to Log.Txt.  
Wrong.

So how do I get ">Log.Txt" to associate with "cmd", not "Start?"


Avatar of sirbounty
sirbounty
Flag of United States of America image

Have you tried a batch file?

@echo off
program "param one" > Log.txt

and then use the start command as:

start /low myprog.bat
ASKER CERTIFIED SOLUTION
Avatar of Qlemo
Qlemo
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial