Hello,
I get AccesViolationE xception with a code when I try to send a packet back to a server. I tried another way with my packet sniffer dll, there I get a SEHexception.
Here is my code I used where I get the AccesViolationE xception:
This is the code from my packet sniffer:
I think the program I'm trying to send to is protected. Does anyone know a work around or a good method to make it work?
All help appreciated, Thanks=D
Greetings,
Polyhymnia
I get AccesViolationE xception with a code when I try to send a packet back to a server. I tried another way with my packet sniffer dll, there I get a SEHexception.
Here is my code I used where I get the AccesViolationE xception:
Code:
Public Declare Auto Function vpSendPacket Lib "VBPCAP.DLL" (ByRef packet() As Byte) As System.Int32
Public Sub sendpacket()
Dim str As Object
str = "00000000 02 3D 00 36 00"
Dim bb() As Byte
bb = StrToByteArray(str)
vpSendPacket(bb)
End Sub
Public Shared Function StrToByteArray(ByVal str As String) As Byte()
Dim encoding As New System.Text.UTF8Encoding()
Return encoding.GetBytes(str)
End Function 'StrToByteArray
Code:
Public Sub sendpacket()
Dim str As Object
str = "00000000 02 3D 00 36 00"
AxPacketXCtrl1.Adapter.SendPacket(str)
End Sub
All help appreciated, Thanks=D
Greetings,
Polyhymnia
Comment