#1
|
||||
|
||||
YYMMDD to YYYY-MM-DD
A very simple question I guess, but I don't know how to do it, so I ask you. How do I format cells so that if I write 091203 it automatically changes to 2009-12-03? (Dates...)
|
#2
|
|||
|
|||
Hi there Alexander,
a truly good and easy solution to this issue probably doesn't exist. I figured out one way of doing this. Assign a user defined format for the relevant cells. In this you enter the format code: "20"00-00-00 (assuming dates are always starting with 20... If you enter 091203, the cell will show 2009-12-03, but... the cell will contain the value 91203 and you can not use it for date calculations, it actually just looks like a date. Another, more difficult solution (but instead with true date format), would be to use VBA. Here is a description of how someone else solved it: http://www.cpearson.com/excel/DateTimeEntry.htm No solution is really nice. I guess you how to live with some extra typing... Best regards Bjorn |
Tags |
date cell formatting |
|