Last active
August 29, 2015 14:14
-
-
Save AdamDimech/3d54bc9a3d61b461e914 to your computer and use it in GitHub Desktop.
Remove the time from an Excel column of data containing date text in the format DD/MM/YY HH:MM:SS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sub StripTimeFromDate() | |
Dim DateTime As Long, i As Long | |
DateTime = Range("D" & Rows.Count).End(xlUp).Row | |
For i = 2 To DateTime | |
With Range("D" & i) | |
.NumberFormat = "dd/mm/yy" | |
.Value = DateValue(.Value) | |
End With | |
Next i | |
End Sub |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment