Password protection not working

Hi,


I am trying to convert html to words with a password protected.

the purpose is to allow read only on the words document.

from the code below, I managed to created a doc from html.
When i try to edit the words file, the words does not prompt me for password and allow any user to edit.

can advice me how can i create a docx so that it will block user from editing before password is entered?

Thanks

Aspose.Words.Document doc = new Aspose.Words.Document();
doc.Protect(ProtectionType.ReadOnly, “pass”);
DocumentBuilder converter = new DocumentBuilder(doc);
///adding html content.
doc.Save(“test.docx”);


Hi Wei Ching,


Thanks for your inquiry. Perhaps, you are using an older version of Aspose.Words; as with Aspose.Words v13.5.0, I am unable to reproduce this problem on my side. I would suggest you please upgrade to the latest version of Aspose.Words i.e. v13.5.0 and let us know how it goes on your side. I hope, this will help.

If the problem still remains, please attach your input html document here for testing. I will investigate the issue on my side and provide you more information.