It looks like all of that is not needed. Try this macro.
[vba]
Option Explicit
Sub Macro1()
With ActivePresentation.SlideMaster.HeadersFooters
With .DateAndTime
.Format = ppDateTimeMdyy
.Text = ""
.UseFormat = msoFalse
.Visible = msoFalse
End With
.Footer.Visible = msoFalse
.SlideNumber.Visible = msoTrue
End With
End Sub
[/vba]