Ok everyone here is the problem. I've written my mgl server and it was
working just fine with one connection. But then I converted it over to
handling multiple connections using the socket wrench OCX. Now everything
was going fine and it even let me log in multiple times however the problem
arose when I sent back information. As soon as I send back information from
my telnet app. It brings up a error in the socket1_read saying that index is
not optional. Now this doesn't make any sense index is the control array
current number it's generated by VB so there is no reason this error should
be coming up. I don't understand why this error is occurring especially
since all the other events of the OCX work just fine with the control array.
The Accept works as the does the disconnect and the send even works but as
soon as I read it brings up that error. The Socket Type I'm using is a
Socket Stream if that helps. The Protocol I'm using IP protocol. So I don't
understand why this is doing this thanks in advance for any help in this
area
Private Sub Socket1_Read(index As Integer, DataLength As Integer, IsUrgent
As Integer)
Debug.Print "index"; index
Socket1(index).RecvLen = DataLength
Buffers(index) = Buffers(index) + Socket1(index).RecvData
'MsgBox (InStr(Buffers(0), vbCr))
Select Case InStr(Buffers(index), vbCr)
Case Is > 0
ParseBuffer Buffers(index)
Socket1(index).RecvLen = 0
Buffers(index) = ""
End Select
'Debug.Print Buffers(index) + "(" + Str(InStr(Buffers(0), vbCr)) + ")"
End Sub
--
- Mark
Havoc Clothing
http://www.*-*-*.com/
Havoc Zine
http://www.*-*-*.com/
The First Law Of Bicycling
"Where ever you ride will be up hill and against the wind"