We are often troubled by the date format shown in the cell, and the date format varies depending on your system language;
650) this.width=650; "style=" Float:none; "title=" 61.JPG "src=" http://s3.51cto.com/wyfs02/M01/6F/E5/ Wkiom1wstcnsnnddaahlnrjwkik152.jpg "alt=" Wkiom1wstcnsnnddaahlnrjwkik152.jpg "/>
and the date format that comes with Excel doesn't necessarily meet our needs.
650) this.width=650; "style=" Float:none; "title=" 62.JPG "src=" http://s3.51cto.com/wyfs02/M02/6F/E2/ Wkiol1wstg3hkqotaahcqxx4xyq186.jpg "alt=" Wkiol1wstg3hkqotaahcqxx4xyq186.jpg "/>
Fortunately, we can customize Excel cell format, how to customize the format, we also need to understand the rules of Excel, here we only share the date of the custom format code.
I'll start by listing a few codes: M; mm;mmm;mmmm;mmmmm; D; dd and so on, which represent different ways of displaying different data.
d use no preamble 0 to show date 1-31
DD uses a leading 0 display date 01-31
DDD uses English abbreviations to show days of the week Sun-sat
DDDD uses the English full name to denote the day of the week Sunday-saturday
AAAA uses Chinese to show days of the week Monday-Sunday
AAA Chinese Display Week sequence one-day
YY two bits to show year 00-99
YYYY using four-bit display year 1900-9999
H using no leading 0 display hours 0-23
HH has leading 0 display hours 00-23
M using no leading 0 display minutes
MM with leading 0 display minutes
Please note the difference with the following
M number showing the month without leading 0 (1-12)
MM with leading 0 digit display month (01-12)
MMM uses English abbreviations to denote the month Jan-dec
MMMM uses the English full name to denote the month January-december
MMMMM Display English initials J-D
Setting a custom format I guess everyone will be here.
650) this.width=650; "style=" Float:none; "title=" 66.JPG "src=" http://s3.51cto.com/wyfs02/M01/6F/E6/ Wkiom1wsvdzwozbuaag-jqahqzw153.jpg "alt=" Wkiom1wsvdzwozbuaag-jqahqzw153.jpg "/>
The results are as follows. How to do whatever you want, how to mix it with you. Enter the same content and apply a different format to show different results.
650) this.width=650; "title=" 63.JPG "src=" http://s3.51cto.com/wyfs02/M01/6F/E6/wKiom1WsvHSBhwwYAAEPWJ4bFm0890.jpg "alt=" Wkiom1wsvhsbhwwyaaepwj4bfm0890.jpg "/>
This article is from the "Guo Yong Technology blog" blog, make sure to keep this source http://guoyong.blog.51cto.com/408495/1676454
Formats for displaying dates in Excel