Detects if a given Ms Office document is protected by a password or not.
Supported formats: Word, Excel and PowerPoint (both legacy and OpenXml).
Namespace:
SautinSoftAssembly: UseOffice (in UseOffice.dll) Version: 5.0.1.29
Syntax
C# | Visual Basic |
public bool IsPasswordProtected( string fileName )
Public Function IsPasswordProtected ( _ fileName As String _ ) As Boolean
Parameters
- fileName
- String
Path to a MS Office document.