Internet Direct (Indy)
Home
PreviousUpNext
IsValidIP Function

Indicates if an argument contains a valid IP address.

Pascal
function IsValidIP(
    const S: String
): Boolean;
Parameters 
Description 
Value to be examined. 

Boolean - True when a dotted-decimal IP address is detected.

IsValidIP is a Boolean function that indicates if the S argument contains a valid IP address in dotted-decimal form. IsValidIP returns True when the string contains 4 decimal segments, each having a value in the range 0 to 255. For example: 

  • "127.0.0.1" returns True.
  • "127.256.0.1" returns False.

Internet Direct (Indy) version 10.1.5
Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Website http://www.indyproject.org.
Post feedback to the Indy Documentation newsgroup.