Home > Software engineering >  A compiler error, variable is undefined, which master can help me, thank you very much.
A compiler error, variable is undefined, which master can help me, thank you very much.

Time:09-24

Option Explicit

Private Sub Form_Load ()
Winsock1. Protocol=sckUDPProtocol

End Sub
Private Sub cncbtn_Click ()
Lclpclbl. Caption=Winsock1. LocalHostName
Winsock1. RemoteHost=RMTPC. Text
Winsock1. RemotePort=RMTPRT. Text
Winsock1. Bind LCLPRT. Text
End Sub

Private Sub sndbtn_Click ()
Winsock1. SendData publishes the event inpttxt. Text
RCVTXT. Text=RCVTXT. Text + CRH $(13) + CRH $(10) + inpttxt. Text

End Sub
Private Sub Winsock1_DataArrival (ByVal bytesTotal As Long)
Dim rcvdata As String
Winsock1. GetData rcvdata
RCVTXT. Text=RCVTXT. Text + CRH $(13) + CRH $(10) + rcvdata

End Sub

CodePudding user response:

Compile time, generally there is an error, the ide will be pointed out, in accordance with the instructions to modify is not ok?

This kind of problems still need to ask?

CodePudding user response:

Trouble specific wrong place, or we don't know how to modify

CodePudding user response:

Menu select "fully compile operation", and then see what went wrong. Find the undefined variable
  • Related