baskar5353
Board Regular
- Joined
- Mar 21, 2015
- Messages
- 114
Hi,
how to change format mm/dd/yyyy to dd/mm/yyyy in VBA.
how to change format mm/dd/yyyy to dd/mm/yyyy in VBA.
Dim StrDt As String
StrDt = InputBox("Input the mm/dd/yyyy date to convert", , "mm/dd/yyyy")
MsgBox StrDt & " to " & Format(Split(StrDt, "/")(1), "00") & "/" & Format(Split(StrDt, "/")(0), "00") & "/" & Format(Split(StrDt, "/")(2), "0000")
Columns("A:A").NumberFormat = "dd/mm/yyyy"