Date: prev next · Thread: first prev next last
2012 Archives by date, by thread · List index

Am 16.07.2012 06:11, Andrew Douglas Pitonyak wrote:
On 07/15/2012 06:52 PM, Andreas Säger wrote:
Calc does not know any dates nor times. It's all about doubles and text.

View this message in context:

Sent from the Users mailing list archive at

Although that is true, I expected a date returned from a function would
return as a double, not text. Internal Date functions in Calc appear to
return as a double and then it is smart enough to display it as a
date.... or am I mistaken?

Sorry, no magic conversion. The double is displayed as date/time when the cell is formatted accordingly. The cell value remains a double. In the context of number format "General", certain input strings are recognized as date/time and number format "General" displays one particular number format for the recognized data type. Once you applied some number format other than the "General" one, any number will be shown in that format. Nevertheless, we can queryContentCells for c.s.s.sheet.CellFlag.DATETIME because the application needs to keep track of those "special doubles" because the base date for the entire document may be changed by the user.

For unsubscribe instructions e-mail to:
Posting guidelines + more:
List archive:
All messages sent to this list will be publicly archived and cannot be deleted


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.