Dim X As Double, Y As Double
Option Explicit
Sub ChangeFormats()
For Y = 1 To 2
For X = 1 To ActiveSheet.Cells(ActiveSheet.Rows.Count, Y).End(xlUp).Row
Cells(X, Y).Value = CDate(Cells(X, Y).Value)
Cells(X, Y).NumberFormat = "dd/mm/yyyy hh:mm:ss AM/PM"
Next X
Next Y
End Sub