#How to password protect pdf free install#The easiest way to install the package is through the Visual Studio Package Manager. Sample code - C# MergeDocument document = new MergeDocument("pdf-a.pdf") ĭocument.Security = Started NuGet PackageĭynamicPDF Core Suite is available on NuGet and is part of the package. Invoke the Draw method on the Document to output the PDF.Create a MergeDocument object with the path to the PDF file.The above security classes can be used to add password protection to an existing PDF document as well. Sample Code - C# Document document = new Document() Īes256Security security = new Aes256Security("owner", "user") ĭocument.Security = to Add Password to PDF Invoke the Draw method on the Document instance to output the PDF.Create a Aes256Security object by setting the owner and user password.Of course, Adobe has a program that can install, change, and remove password protection. Not a trick, but the official method: Adobe Acrobat Pro. The new file will be exactly the same as the original, just without the password.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |