Products Downloads


French version


 

 

This function retrieves a computer's name based on its IP address (IPv4 or IPv6).

 

Context

  • Windows client,

  • Windows server,

  • Java client,

  • Java server,

  • Adelia Web client,

  • Adelia Cloud client,

  • Event Adelia client.

 

Parameters

ALPHA(n) [I]

IPAddress

IP address (IPv4 or IPv6).

Note: text representation of an IPv6 address in accordance with the specification RFC2373.

 

On Windows platforms, native support for IPv6 addresses is provided by Windows Vista, Windows Server 2008 and later operating systems.

ALPHA(n) [O]

ComputerName

Computer name.

NUM_BIN_2 [I]

Size

Size (n) of the ComputerName parameter.

NUM_BIN_4 [O]

ReturnCode

Return code for the operation:

 0: Operation completed successfully.

-1: Unknown host or incorrectly formatted IP address.

-3: ComputerName buffer too small.

 

[C platform]

> 0: Winsock error.

 -2: IPv6 address not supported.

 

[Java platform]

1: Security error.

 

Example

ALPHA(15)

IPAddress

ALPHA(100)

ComputerName

NUM_BIN_2

Size

NUM_BIN_4

ReturnCode

 

IPAddress

= ' 194.3.108.125 '

Size

= 100

 

 

CALL_DLL

'VATOOLBX' 'VaToolBxGetHostByIP' IPAddress ComputerName Size ReturnCode

 

Result:

ReturnCode

= 0 /* the operation was completed successfully.

ComputerName

= 'sametime.hardis.com'

 

 

ALPHA(100)

ComputerName

NUM_BIN_4

ReturnCode

 

CALL_DLL

'VATOOLBX' 'VaToolBxGetHostByIP' ' ::1' ComputerName 100 ReturnCode

 

Result:

ReturnCode

= 0 /* the operation was completed successfully.

ComputerName

= 'PS421.hardis.com'

 

List of the VaToolBx functions by topic

 

↑ Top of page


  • Aucune étiquette