georgepatotk
Well-known member
I have a big doubt which i had already spent few days on t but still cant achieve the solution. Please help me.
I want to break a packet(in byte) into smaller packet (512 bytes) and reassemble it. can anyone tell me how to do that? Below is the demo code that i had created, please guide me. I have a comment on that code.
I want to break a packet(in byte) into smaller packet (512 bytes) and reassemble it. can anyone tell me how to do that? Below is the demo code that i had created, please guide me. I have a comment on that code.
Code:
Private CombinedBytes() As Byte
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim al As New ArrayList
For a As Integer = 1 To 12000
al.Add(a)
Next
Dim serializer As New System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
Dim myStream As New System.IO.MemoryStream
serializer.Serialize(myStream, al)
Dim sendBytes As [Byte]() = myStream.GetBuffer
CombinedBytes = sendBytes
instead of this, i want to break it and reassemble it into CombinedBytes
this is just a demo, i just want to know how to break and then assemble it