Dim arr As New ArrayList()
arr.Add("AAA")
arr.Add("BBB")
arr.Add("CCC")
Dim byteArray As Byte() = New Byte(2) {}
For i As Integer = 0 To arr.Count - 1
byteArray = DirectCast(arr(i), Byte())
Next
'Read byteArray to stream
Dim stream As New System.IO.MemoryStream(byteArray)
vinz
All-Star
127026 Points
17936 Posts
MVP
Re: how do i read a byte array into a stream?
Oct 06, 2008 07:32 PM|LINK
Try this example below using ArrayList..
Dim arr As New ArrayList() arr.Add("AAA") arr.Add("BBB") arr.Add("CCC") Dim byteArray As Byte() = New Byte(2) {} For i As Integer = 0 To arr.Count - 1 byteArray = DirectCast(arr(i), Byte()) Next 'Read byteArray to stream Dim stream As New System.IO.MemoryStream(byteArray)MessageBox Controls for WebForms | Blog | Twitter | Linkedin