.NET Framework 4.5.2+
.NET Framework 4.5.2+
.NET Standard 2.0+

Document.Protect Method

Name Parameters Description
Protect(String) password Protects a document with a given password.
Protect(String, DocumentProtectionType) password, protectionType Enforces document protection and sets the specified password.