devxlogo

Check Whether or Not an IP Is Valid in C#

Check Whether or Not an IP Is Valid in C#

See below for a short function that validates a given IP address:

public static Boolean ValidateIP(string inputIP){var ipParts = inputIP.Split('.');return Int32.Parse(ipParts [0]) 

devx-admin

Share the Post: