1. public bool IsDate(object value)
    {
    bool result = false;
    string strDate = value.ToString();

    try
    {
    DateTime dt = DateTime.Parse(strDate);
    if(dt != DateTime.MinValue && dt != DateTime.MaxValue)
    result = true;
    }
    catch (Exception ex)
    {
    result = false;
    }

    return result;
    }
    0

    Add a comment

Blog Archive
Topics
Topics
Loading
Dynamic Views theme. Powered by Blogger. Report Abuse.