diff --git a/lib/Excel/Writer/XLSX.pm b/lib/Excel/Writer/XLSX.pm index 170b6c56..0242a8a3 100644 --- a/lib/Excel/Writer/XLSX.pm +++ b/lib/Excel/Writer/XLSX.pm @@ -3807,7 +3807,7 @@ Using format strings you can define very sophisticated formatting of numbers. $worksheet->write( 8, 0, 36892.521, $format09 ); # 1 January 2001 $format10->set_num_format( 'dd/mm/yyyy hh:mm AM/PM' ); - $worksheet->write( 9, 0, 36892.521, $format10 ); # 01/01/2001 12:30 AM + $worksheet->write( 9, 0, 36892.521, $format10 ); # 01/01/2001 12:30 PM $format11->set_num_format( '0 "dollar and" .00 "cents"' ); $worksheet->write( 10, 0, 1.87, $format11 ); # 1 dollar and .87 cents @@ -4400,7 +4400,7 @@ If you write a date string with C then all you will get is a string: $worksheet->write( 'A1', '02/03/04' ); # !! Writes a string not a date. !! -Dates and times in Excel are represented by real numbers, for example "Jan 1 2001 12:30 AM" is represented by the number 36892.521. +Dates and times in Excel are represented by real numbers, for example "Jan 1 2001 12:30 PM" is represented by the number 36892.521. The integer part of the number stores the number of days since the epoch and the fractional part stores the percentage of the day. diff --git a/lib/Excel/Writer/XLSX/Utility.pm b/lib/Excel/Writer/XLSX/Utility.pm index a1582328..7d06dc03 100644 --- a/lib/Excel/Writer/XLSX/Utility.pm +++ b/lib/Excel/Writer/XLSX/Utility.pm @@ -1104,7 +1104,7 @@ This functions takes a cell reference string in A1 notation and decrements the c =head1 TIME AND DATE FUNCTIONS -Dates and times in Excel are represented by real numbers, for example "Jan 1 2001 12:30 AM" is represented by the number 36892.521. +Dates and times in Excel are represented by real numbers, for example "Jan 1 2001 12:30:14 PM" is represented by the number 36892.521. The integer part of the number stores the number of days since the epoch and the fractional part stores the percentage of the day in seconds. @@ -1112,7 +1112,7 @@ A date or time in Excel is like any other number. To display the number as a dat $date = xl_date_list( 2001, 1, 1, 12, 30 ); $format->set_num_format( 'mmm d yyyy hh:mm AM/PM' ); - $worksheet->write( 'A1', $date, $format ); # Jan 1 2001 12:30 AM + $worksheet->write( 'A1', $date, $format ); # Jan 1 2001 12:30 PM The date handling functions below are supplied for historical reasons. In the current version of the module it is easier to just use the C function to write dates or times. See the DATES AND TIME IN EXCEL section of the main L documentation for details.