Parse Twitter Time - CSharp System

CSharp examples for System:DateTime Parse

Description

Parse Twitter Time

Demo Code


using System.Web;
using System.Linq;
using System.Globalization;
using System.Collections.Generic;
using System;//w ww. j a  va2s. c  o  m

public class Main{
        public static DateTime ParseTwitterTime(this string date)
        {
            const string format = "ddd MMM dd HH:mm:ss zzzz yyyy";
            return DateTime.ParseExact(date, format, CultureInfo.InvariantCulture);
        }
}

Related Tutorials