PPT
PPTX
ODP
POT
ppsx
PPT
Lock or Password Protect PPT using Java
Build your own Java apps to protect presentation files using server-side APIs.
Protecting a PPT Presentation via Java
Using Aspose.Slides for Java, you can protect your PPT presentation from opening or modification by setting a password. Then, to open or modify the locked presentation, a user has to provide the password.
Encrypting a PPT Presentation using Java
Presentation presentation = new Presentation("pres.ppt");
try {
presentation.getProtectionManager().encrypt("123123");
presentation.save("encrypted-pres.ppt", SaveFormat.Ppt);
} finally {
if (presentation != null) presentation.dispose();
}
Setting Write Protection to a PPT Presentation using Java
Presentation presentation = new Presentation("pres.ppt");
try {
presentation.getProtectionManager().setWriteProtection("123123");
presentation.save("write-protected-pres.ppt", SaveFormat.Ppt);
} finally {
if (presentation != null) presentation.dispose();
}
How to Password Protect PPT via Java
These are the steps to Protect PPT files.
Load PPT with an instance of Presentation
Protect the presentation using ProtectionManager class
Save result in PPT format