Name
GetLocalIP -- get IP address of local side (V5.0)
Synopsis
ip$ = GetLocalIP(id[, type])
Function
This command returns the IP address on the local side of the network object specified in id. The optional argument type specifies the type of the network object passed in argument 1. The following types are currently supported by this function:

#NETWORKCONNECTION:
Query the local IP of a connection obtained by a call to OpenConnection(), or the local IP of a client connection obtained by listening to the OnConnect and OnReceiveData events that can be installed using the command InstallEventHandler().

#NETWORKSERVER:
Query the local IP of a server established using the CreateServer() call.

#NETWORKUDP:
Query the local IP of an UDP object created using the CreateUDPObject() call.

If you omit the optional type argument, it will default to type #NETWORKCONNECTION.

Inputs
id
network object to query
type
optional: type of the network object passed in argument 1 (defaults to #NETWORKCONNECTION)
Results
ip$
IP address of the local side of the connection

Show TOC