Private Sub Document_ContentControlOnExit(ByVal ContentControl As ContentControl, Cancel As Boolean)
Dim pStr As String
If Val(Application.Version) 14 Then Main.SetDeveloperTabActive
pStr = ContentControl.Range.Text
If ContentControl.Type = wdContentControlDate Then
If Not IsDate(pStr) Then
MsgBox "You must enter a date", vbCritical, "Completion error"
Cancel = True
End If
End If
End Sub
|