Check that the TypeName function does not return Nothing when run on the ActiveInspector method of the Application object: : ActiveInspector « Application « VBA / Excel / Access / Word






Check that the TypeName function does not return Nothing when run on the ActiveInspector method of the Application object:

 
Sub active()
    If TypeName(Application.ActiveInspector) = "Nothing" Then
        MsgBox "No item is open."
        End
    End If
End Sub

 








Related examples in the same category

1.Working with the Active Inspector
2.Using the Close Method
3.Using the SaveAs Method