Convert Word to PDF file - with bookmark enabled

Hi,

We are in the process of evaluating the Aspose word to PDF conversion DLL.
We are using the Aspose.Words_15.5.0. We were able to covert the normal word document to PDF files.

While converting the word document to PDF, the bookmark option in the converted PDF file is not enabled. How can this be done?

Regards,
Ansu

Hi Ansu,
You can specify PdfSaveOptions.OutlineOptions.DefaultBookmarksOutlineLevel option to enable bookmarks at any level e.g.

Document doc = new Document("Input.docx");
PdfSaveOptions options = new PdfSaveOptions();
options.OutlineOptions.DefaultBookmarksOutlineLevel = 1;
doc.Save("Out.pdf", options);

Default value for PdfSaveOptions.OutlineOptions.DefaultBookmarksOutlineLevel is 0 which means bookmarks will not be displayed. You can specify any value from 0 to 9. Specify 1 and Word bookmarks will be displayed in the document outline at level 1; 2 for level 2 and so on.
Best Regards,

Thanks it worked perfect