CSharp · Console
// C# Extension Method
// Doc: https://csharp-extension.com/en/method/1002470/object-isvaliduint32
// @nuget: Z.ExtensionMethods
using System;
public class Program
{
public static void Main()
{
string format = "{0, -40} {1, -15}";
object [] values = { "-128" , "89","ABC", "true", "12/31/2018", "899", ".", "546565255465", "10888", "5465665", "4/2/2007 7:23:57 PM -07:00"};
Console.WriteLine(format, "Object", "Is Valid UInt32");
Console.WriteLine(format, "------", "---------------");
foreach(var val in values)
{
// C# Extension Method: Object - IsValidUInt32
Console.WriteLine(format, val, val.IsValidUInt32());
}
}
}