heathb
05-09-2017, 09:28 AM
Hi all,
I have a savedate function that works fine when run in London, howere returns a time when run in holland?? I am presuming it is a default format in excle rather than vba, but how do I change it please[
HTML]Dim ndate As Date
Dim savedate As Variant
ndate = Range("cz2").Value
savedate = Mid(ndate, 1, 2) & "_" & Mid(ndate, 4, 2) & "_" & Mid(ndate, 7, 4)[/HTML]
field cz2 is populated as = 2017/05/08
in London this returns ndate = 08/05/2017
in holland this returns ndate = 12:00:00 AM
Will log this on the excle as well just in case.
Thanks in advance for any help
I have a savedate function that works fine when run in London, howere returns a time when run in holland?? I am presuming it is a default format in excle rather than vba, but how do I change it please[
HTML]Dim ndate As Date
Dim savedate As Variant
ndate = Range("cz2").Value
savedate = Mid(ndate, 1, 2) & "_" & Mid(ndate, 4, 2) & "_" & Mid(ndate, 7, 4)[/HTML]
field cz2 is populated as = 2017/05/08
in London this returns ndate = 08/05/2017
in holland this returns ndate = 12:00:00 AM
Will log this on the excle as well just in case.
Thanks in advance for any help