Il giorno Thu, 7 Aug 2008 01:50:50 -0700 (PDT), lucadentella@xxxxxx ha scritto:
Quote:
>I'm working on a script to automate SFTP operations (using a text-
>based sftp client).
>My idea is to use the Exec() method to run the client, send commands
>via StdIn and receive output via StdOut and StdErr.
>
>The problem is that when I try to read buffers using ReadAll or
>AtEndOfStream, those methods are blocking and never ends... for StdOut
>I was able to find a condiction (when I read "sftp>" from the buffer)
>to end reading, but for StdErr? Is there a way to know how many chars
>are in the buffer to use the Read(n) method which is not blocking?
Hello,
I dropped a project I was working on (reading e-mails using vbs as an interface for
netcat) because I had some problems as yours.
Can you confirm I can read a stream before it is closed and while the output is still
being writing?
Thank you.
Giovanni.
--
Giovanni Cenati (Bergamo, Italy)
Write to "Reventlov" at katamail com
http://digilander.libero.it/Cenati (Esempi e programmi in VbScript)
--