Date and Time Format Patterns

Date and Time Format Patterns

Copas from :

http://authors.aspalliance.com/aspxtreme/sys/globalization/demos/ DateTimeFormatInfoGetAllDateTimePatterns.aspx

All the patterns:

0

MM/dd/yyyy

09/15/2010

1

dddd, dd MMMM yyyy

Wednesday, 15 September
2010

2

dddd, dd MMMM yyyy HH:mm

Wednesday, 15 September
2010 00:35

3

dddd, dd MMMM yyyy hh:mm
tt

Wednesday, 15 September
2010 12:35 AM

4

dddd, dd MMMM yyyy H:mm

Wednesday, 15 September
2010 0:35

5

dddd, dd MMMM yyyy h:mm
tt

Wednesday, 15 September
2010 12:35 AM

6

dddd, dd MMMM yyyy
HH:mm:ss

Wednesday, 15 September
2010 00:35:07

7

MM/dd/yyyy HH:mm

09/15/2010 00:35

8

MM/dd/yyyy hh:mm tt

09/15/2010 12:35 AM

9

MM/dd/yyyy H:mm

09/15/2010 0:35

10

MM/dd/yyyy h:mm tt

09/15/2010 12:35 AM

11

MM/dd/yyyy HH:mm:ss

09/15/2010 00:35:07

12

MMMM dd

September 15

13

MMMM dd

September 15

14

yyyy’-‘MM’-‘dd’T’HH’:’mm’:’ss.fffffffK

2010-09-15T00:35:07.4151985-04:00

15

yyyy’-‘MM’-‘dd’T’HH’:’mm’:’ss.fffffffK

2010-09-15T00:35:07.4151985-04:00

16

ddd, dd MMM yyyy
HH’:’mm’:’ss ‘GMT’

Wed, 15 Sep 2010 00:35:07
GMT

17

ddd, dd MMM yyyy
HH’:’mm’:’ss ‘GMT’

Wed, 15 Sep 2010 00:35:07
GMT

18

yyyy’-‘MM’-‘dd’T’HH’:’mm’:’ss

2010-09-15T00:35:07

19

HH:mm

00:35

20

hh:mm tt

12:35 AM

21

H:mm

0:35

22

h:mm tt

12:35 AM

23

HH:mm:ss

00:35:07

24

yyyy’-‘MM’-‘dd
HH’:’mm’:’ss’Z’

2010-09-15 00:35:07Z

25

dddd, dd MMMM yyyy
HH:mm:ss

Wednesday, 15 September
2010 00:35:07

26

yyyy MMMM

2010 September

27

yyyy MMMM

2010 September

The patterns for
DateTime.ToString ( ‘d’ ) :

0

MM/dd/yyyy

09/15/2010

The patterns for
DateTime.ToString ( ‘D’ ) :

0

dddd, dd MMMM yyyy

Wednesday, 15 September
2010

The patterns for
DateTime.ToString ( ‘f’ ) :

0

dddd, dd MMMM yyyy HH:mm

Wednesday, 15 September
2010 00:35

1

dddd, dd MMMM yyyy hh:mm
tt

Wednesday, 15 September
2010 12:35 AM

2

dddd, dd MMMM yyyy H:mm

Wednesday, 15 September
2010 0:35

3

dddd, dd MMMM yyyy h:mm
tt

Wednesday, 15 September
2010 12:35 AM

The patterns for
DateTime.ToString ( ‘F’ ) :

0

dddd, dd MMMM yyyy
HH:mm:ss

Wednesday, 15 September
2010 00:35:07

The patterns for
DateTime.ToString ( ‘g’ ) :

0

MM/dd/yyyy HH:mm

09/15/2010 00:35

1

MM/dd/yyyy hh:mm tt

09/15/2010 12:35 AM

2

MM/dd/yyyy H:mm

09/15/2010 0:35

3

MM/dd/yyyy h:mm tt

09/15/2010 12:35 AM

The patterns for
DateTime.ToString ( ‘G’ ) :

0

MM/dd/yyyy HH:mm:ss

09/15/2010 00:35:07

The patterns for
DateTime.ToString ( ‘m’ ) :

0

MMMM dd

September 15

The patterns for
DateTime.ToString ( ‘r’ ) :

0

ddd, dd MMM yyyy
HH’:’mm’:’ss ‘GMT’

Wed, 15 Sep 2010 00:35:07
GMT

The patterns for
DateTime.ToString ( ‘s’ ) :

0

yyyy’-‘MM’-‘dd’T’HH’:’mm’:’ss

2010-09-15T00:35:07

The patterns for
DateTime.ToString ( ‘u’ ) :

0

yyyy’-‘MM’-‘dd
HH’:’mm’:’ss’Z’

2010-09-15 00:35:07Z

The patterns for
DateTime.ToString ( ‘U’ ) :

0

dddd, dd MMMM yyyy
HH:mm:ss

Wednesday, 15 September
2010 00:35:07

The patterns for
DateTime.ToString ( ‘y’ ) :

0

yyyy MMMM

2010 September

Comments are closed.

RSS
Follow by Email
Facebook
Twitter
Visit Us
Follow Me
INSTAGRAM