OpenNetworkConnection()
Syntax
Connection = OpenNetworkConnection(ServerName$, Port [, Mode])Description
Try to open a connection on the specified server. 'ServerName$' can be an IP address or a full name (ie: "127.0.0.1" or "ftp.home.net").
If the connection has be granted by the server, the 'Connection' is not NULL, otherwise the connection has failed. 'Connection' is needed by all receive and send commands.
The optional 'Mode' parameter can be one of the following value:#PB_Network_TCP: The connection will use the TCP network protocol (default) #PB_Network_UDP: The connection will use the UDP network protocol. The connection will not be explicitely created, as UDP is a connection less protocol, but it will add an entry in the PureBasic management stack and allow to send data via UDP using the regular SendNetworkData() and such commands.
Supported OS
All