WSPortFromLinkServer (C Function)

unsigned short WSPortFromLinkServer(WSLinkServer s, int *err)

returns the TCPIP port number used by link server s.

Details

  • If WSPortFromLinkServer() succeeds err will contain 0. If WSPortFromLinkServer() failes, err will contain a nonzero error code.
  • The nonzero values that indicate an error condition correspond to the WSE error codes in wstp.h and as returned by WSError().

Examples

Basic Examples  (1)

#include "wstp.h"

unsigned short getPortFromLinkServer(WSLinkServer server)
{
    return WSPortFromLinkServer(server);
}