wxProcess

BlitzMax Modules Forums/Brucey's Modules/wxProcess

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Here's one working with the latest code :
SuperStrict

Framework wx.wxApp
Import wx.wxProcess

New MyApp.run()


Type MyApp Extends wxApp

	Method OnInit:Int()

		Local m_versionProcess:wxProcess = New wxProcess.CreateWithFlags(wxPROCESS_REDIRECT)

		Local command:String = "lst"
		Local m_pid:Int = wxExecute(command, wxEXEC_SYNC, m_versionProcess )

		Local p_in:wxInputStream = m_versionProcess.GetInputStream()

		If p_in Then

			Local textInput:wxTextInputStream = New wxTextInputStream.Create(p_in)

			While Not p_in.Eof()
		
				DebugLog textInput.ReadLine()

			Wend
					
		End If
		
		m_versionProcess.free
		
		Return False
	
	End Method

End Type


:o)