![]() |
Format problem
Hi
I have a download from a generic program that sends dates as follows 20061230 and I need to automatically change the formating to read 30/12/2006 so that I can perform other calculations on the date, how can I do this? |
Format problem
Steve,
You could do something similar with an Excel formula also: Public Function ConvDate(inDate As String) As Date ConvDate = DateSerial(Left(inDate, 4), Mid(inDate, 5, 2), Right(inDate, 2)) End Function NickHK "Steve Wood" wrote in message ... Hi I have a download from a generic program that sends dates as follows 20061230 and I need to automatically change the formating to read 30/12/2006 so that I can perform other calculations on the date, how can I do this? |
Format problem
Steve
You could also simply try: =TEXT(A1+0,"0000-00-00")+0 and format the cell as dd/mm/yyyy Richard NickHK wrote: Steve, You could do something similar with an Excel formula also: Public Function ConvDate(inDate As String) As Date ConvDate = DateSerial(Left(inDate, 4), Mid(inDate, 5, 2), Right(inDate, 2)) End Function NickHK "Steve Wood" wrote in message ... Hi I have a download from a generic program that sends dates as follows 20061230 and I need to automatically change the formating to read 30/12/2006 so that I can perform other calculations on the date, how can I do this? |
All times are GMT +1. The time now is 09:59 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com