[mono-vb] Re directing output of console application to stream

Easy_Rider9999 jhmgbl2 at t-online.de
Sat Nov 14 14:25:45 EST 2009




Easy_Rider9999 wrote:
> 
> It is not possible to set p.StartInfo.RedirectStandardOutput = true,
> because this is not implemented. Does anybody know another possibility for
> getting the output of a console-application?
> 
> Regards Hans
> 

I get the following Error:

/home/jhmgbl/Projects/prjLinuxInfo/prjLinuxInfo/frmMain.vb (144,7) : Error
VBNC30456: 'RedirectStandartOutput' is not a member of
'System.Diagnostics.ProcessStartInfo'.


The Code is:

Private Sub xvinfo
			Dim p as new system.diagnostics.process
			Dim si as System.Diagnostics.ProcessStartInfo = p.StartInfo
			si.CreateNoWindow = true
			si.UseShellExecute = false
			si.RedirectStandartOutput = true
			si.FileName = "xvinfo"
			Dim s as IO.StreamReader = p.StandardOutput
			Dim l as String
			p.start
			Do While (l = s.ReadLine) isnot nothing 
				Dim iter as TreeIter = store.AppendValues(RootIter,l)
			Loop
			p.waitforexit
			
			
		End Sub
		


-- 
View this message in context: http://old.nabble.com/Redirecting-output-of-console-application-to-stream-tp26343579p26353066.html
Sent from the Mono - VB mailing list archive at Nabble.com.



More information about the Mono-vb mailing list