Change
to
in my original macro thus
Code:
Option Explicit
Sub Macro1()
'Graham Mayor - http://www.gmayor.com - Last updated - 02 Nov 2017
Dim iShp As Integer
Dim dStartDate As Date
Dim oRng As Range
Dim strDate As String
dStartDate = "31/12/2017"
For iShp = 1 To ActiveDocument.InlineShapes.Count
strDate = Format((dStartDate + iShp), "mmmm d") & _
DateOrdinal(Format((dStartDate + iShp), "d")) & _
Format((dStartDate + iShp), " yyyy")
Set oRng = ActiveDocument.InlineShapes(iShp).Range
oRng.Collapse 1
oRng.Text = vbCr & strDate & vbCr
Set oRng = oRng.Paragraphs(2).Range
oRng.Font.Size = 24
oRng.ParagraphFormat.Alignment = wdAlignParagraphCenter
Next iShp
lbl_Exit:
Set oRng = Nothing
Exit Sub
End Sub
Private Function DateOrdinal(Val As Long) As String
Dim strOrd As String
If (Val Mod 100) < 11 Or (Val Mod 100) > 13 Then strOrd = Choose(Val Mod 10, "st", "nd", "rd") & ""
DateOrdinal = IIf(strOrd = "", "th", strOrd)
End Function