Re: how to redirect output by GS
GS
Sun Oct 15 01:48:14 CDT 2006
thank you very much. just what I need. This enabled me to write a more
reliable script to determine free space in a directory for backups
"Alexander Mueller" <millerax@hotmail.com> wrote in message
news:45317ea0$0$30580$9b4e6d93@newsspool4.arcor-online.net...
> 15.10.2006 02:14, Alexander Mueller schrieb:
>
> >> in a vbs script I would like toe executer and command batch files and
> >> redirect the its output to vbs script directly.
> >> How to I do that?
>
> > Set ws = CreateObject ("WScript.Shell")
> > Set exec = ws.Execute ("cmd /c dir C:\")
>
> Typo, should read as follows:
>
> Set exec = ws.Exec ("cmd /c dir C:\")
>
> > output = exec.Stdout.ReadAll
> > WSH.Echo output
>
> MfG,
> Alex