Jump to content

TCP errors!


benzrf
 Share

Recommended Posts

I've been getting really weird results, if not errors, when I try to use the TCP functions. With something like

TCPStartup()
$socket = TCPListen("192.168.1.3", 64432)

MsgBox(0, @error, $socket)
I get a msgbox with the caption "0" and the text "1688". ALWAYS. Even when I pick another port (except for ones that are already in use like 80 (I have an HTTP running)). I don't have any kind of program running that would do that. Unless... My father recently installed WebRoot. That couldn't be it, could it?

Thanks in advance.

Link to comment
Share on other sites

TCPStartup()
$socket = TCPListen(@IPAddress1, 64432)
MsgBox(0, @error, $socket)

The return you are getting is normal. Its the socket identifier. What are you trying to achieve?

Try this, and then open a cmd and "telnet 127.0.0.1 64432" - you'll see it works.

TCPStartup()
$socket = TCPListen("127.0.0.1", 64432)

While True
    $conns =  TCPAccept($socket)
    if $conns >= 0 Then
        MsgBox(0, "Connected", "Connection received")
        exit
    EndIf
WEnd
Edited by Steveiwonder

They call me MrRegExpMan

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...