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


Andreas Säger wrote
All this conversion from strings to numbers is unrelated to the date
acceptance patterns that determines how Calc turns your keyboard input
into day numbers.

No, it is not just for keyboard entry!  And, it is certainly applicable for
format conversion of non-local date formats entered as text strings.

The OP says his data is already entered in the sheet as text strings:

"Column A has *text* strings that are DD/MM/YYYY format.
I want to make them real dates..."

So, needs an efficient way for those text strings to be converted to dates
(in interger value).

When the column selection is cell formatted as Date,  these existing text
strings will show with a single quote preceding on the formula bar. 

The existing text stings are forcibly recast, easily done with a Selction,
then an Edit -> Find-Replace using Regular expression of "^[0-9]" and
replaced with  "&" for the Selection--which will cast text strings to
numbers-- which now within a date field, as controlled by "date acceptance
pattern", become valid dates.

<http://nabble.documentfoundation.org/file/n4144356/Find_Replace_RegEx_convertStringsDates.png> 

So,  for the example of existing text strings, enter the matching "Date
acceptance pattern" of D/M/Y (and suppress any others if needed)--and then
recast the text strings 'DD/MM/YYY as dates.




--
View this message in context: 
http://nabble.documentfoundation.org/converting-txt-to-dates-tp4143826p4144356.html
Sent from the Users mailing list archive at Nabble.com.

-- 
To unsubscribe e-mail to: users+unsubscribe@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Context


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.