shawnnason
Programmer
I am trying to write an application that will connect to different computer at run time by specifiying, in a text ox, the name of the computerto which I want to connect. I am using Winsock for this. I know that I can use the "friendly" name or the dotted noation. I have my form load do, among other things this:
Code:
tcpClient.RemoteHost = txtConnectToName.text
[\code]
with txtConnectToName set at desing time with a default value. I then check at run time what the value of txtConnectToName is via a msgbox, and I get the new name. However, when I get to the next line, which is again the RemoteHost call, I get an error:
[code]
MsgBox (txtConnectToName.text)
tcpClient.RemoteHost = txtConnectToName.text
[\code]
The error is:
Run Time Error 40020:
Invalid Operation at current state
I am guessing that I need to do something to the Winsock tcpClient first, but what?
- Shawn