bobkasterop
New Member
- Joined
- May 10, 2018
- Messages
- 6
Hey, so i have to change the date format in an excel sheet from yy-mm-dd to dd-mm-yy.
i tried using numberformat like this 'Range("A2", "A50000").NumberFormat = "dd-mm-yy"' but this doesnt change anything.
i also tried using format(Date,"dd-mm-yy") but this just sets the cell to have the date of today (from my computer)
i think that the reason for numberformat not working is that Excel doesnt really know which of the bits is yy which is dd and which is mm and therefore is thinking that they are allready in the right order.
my question is therefore:
how do i make excel now that right now it is in the order of yy-mm-dd? so that i aftwerwards can use numberformat.
i tried using numberformat like this 'Range("A2", "A50000").NumberFormat = "dd-mm-yy"' but this doesnt change anything.
i also tried using format(Date,"dd-mm-yy") but this just sets the cell to have the date of today (from my computer)
i think that the reason for numberformat not working is that Excel doesnt really know which of the bits is yy which is dd and which is mm and therefore is thinking that they are allready in the right order.
my question is therefore:
how do i make excel now that right now it is in the order of yy-mm-dd? so that i aftwerwards can use numberformat.