To Iso Date Time - CSharp System

CSharp examples for System:DateTime Format

Description

To Iso Date Time

Demo Code


using System;//from   w ww . j  a  va2  s . co m

public class Main{
        public static string ToIsoDateTime(this DateTime datetime)
        {
            return datetime.ToString("yyyy-MM-dd HH':'mm':'ss");
        }
}

Related Tutorials