1
0
mirror of https://e.coding.net/circlecloud/MCServer_Protocol.git synced 2024-12-26 20:38:47 +00:00

添加未连接屏蔽模块...

Signed-off-by: j502647092 <jtb1@163.com>
This commit is contained in:
j502647092 2015-08-07 20:51:09 +08:00
parent a2a721b14b
commit 988af6570b
3 changed files with 14 additions and 4 deletions

View File

@ -12,6 +12,14 @@ Begin VB.Form Frm_Main
MinButton = 0 'False
ScaleHeight = 8385
ScaleWidth = 8880
Begin VB.Frame b
Caption = "δÁ¬½Ó"
Height = 4680
Left = 75
TabIndex = 44
Top = 3720
Width = 8820
End
Begin VB.TextBox protocolver
Height = 300
Left = 6075
@ -560,11 +568,13 @@ Private Sub Wsk_Close(Index As Integer)
Wsk(Index).Close
If autosend.Value = 1 Then Wsk(Index).connect addr, port
keeplive(Index).Enabled = False
b.Visible = True
End Sub
Private Sub Wsk_Connect(Index As Integer)
Dim tempip As String
Dim rndusername As String
b.Visible = False
List1.AddItem Index & " Á¬½Óµ½·þÎñÆ÷£¡"
List1.AddItem Wsk(Index).RemoteHostIP
Text1(0) = Encode(addr.Text & ":" & port.Text, EncodeIP, "00-" + hhex(protocolver.Text), "01")
@ -598,7 +608,7 @@ Private Sub Wsk_DataArrival(Index As Integer, ByVal bytesTotal As Long)
Wsk(Index).GetData bytes, vbByte + vbArray
If getdatac.Value = 1 Then
For i = LBound(bytes) To UBound(bytes)
Temp = Temp & hex(bytes(i)) & " "
Temp = Temp & hhex(bytes(i)) & " "
DoEvents
Next
List1.AddItem Temp

View File

@ -1,3 +1,3 @@
MC_TCP = 327, 29, 1823, 725,
Frm_Main = 0, 0, 1496, 615, , 22, 22, 644, 715, C
MC_TCP = 643, 21, 2139, 717,
Frm_Main = 712, 33, 1473, 648, , 22, 22, 644, 715, C
UTF8COde = 0, 0, 0, 0, C

View File

@ -55,7 +55,7 @@ Function hextobyte(hex As String)
hextobyte = bytes
End Function
Public Function hhex(data As Long) As String
Public Function hhex(ByVal data As Long) As String
Dim Temp As String
Temp = hex(data)
If Len(Temp) = 1 Then Temp = "0" + Temp