Iam trying send command to the server to respond after the conenction is made.

Private sub Send_Click()

tcpclient.connect
Sleep(1000)
txtsend.Text = "some.txt"
tcpClient.Senddata txtsend.text & Chr$(10) ---- error here
end sub

this code gives me an error in the send data command as wrong protocol or connection state for the requested transaction.

need help