Stefan Litzel wrote:But when i try to write the pass to the console nothing happens.
Is your code even getting that far? You are reading from the process' output stream until EOF (indicated by a null). I wouldn't expect that to happen until the process terminates. Try printing to the screen between your read and write.