There is a DocSavingOptions class in Aspose.Words.Saving namespace, but I couldn’t find any info on how to use it.
Hi Carla,
Thanks
for your inquiry. Encrypted documents can be loaded into Aspose.Words
as long as the password supplied on load for the document is correct. Please check following code snippet.
Document doc = new Document(“Document.LoadEncrypted.doc”, new LoadOptions(“password”));
DocSaveOptions Constructor initializes a new instance of this class that can be used to save a document in the Doc or Dot format.
OoxmlSaveOptions Constructor initializes a new instance of this class that can be used to save a document in the Docx, Docm, Dotx, Dotm or FlatOpc format.
Please check following code examples for your kind reference and let us know if you have any more queries.
LoadOptions options = new LoadOptions();
options.Password = “test”;
Document doc = new Document(MyDir + “in.doc”, options);
DocSaveOptions saveoptions = new DocSaveOptions();
saveoptions.Password = “new password”;
doc.Save(MyDir + “Out.doc”, saveoptions);
Document doc = new Document(MyDir + “in.docx”);
OoxmlSaveOptions options = new OoxmlSaveOptions(SaveFormat.Docx);
options.Password = “test”;
doc.Save(MyDir + “Out.docx”, options);
Tahir, I got it to work for MS Word
Hi Carla,
for your inquiry. I am moving this forum thread to Aspose.Total forum. My colleagues from Aspose.Cells team will reply you shortly about your query.
Hi,
Thanks Amjad