@PINGDHCP — Returns the address of a DHCP server.

Syntax:
%@PINGDHCP[n]

nthe index (1-N) of the server to return, or 0 for the number of known DHCP servers

Only IPv4 is supported. If n is omitted, it defaults to 1 (return the first DHCP server). On any error, this function returns an empty string.


rem    List known DHCP servers:

do i = 1 to %@pingdhcp[0]
   echo DHCP #%i:  %@pingdhcp[%i]
enddo


This function is equivalent to APING’s #DHCP macro, but can be used in other commands.