Sub Test() If ActiveDocument.Views.Count > 1 Then MsgBox "There are no views in the current document", vbCritical End IfEnd Sub