I just downloaded the latest 6.3.0.0 .net Aspose.Word. I have a doc which has lots of bookmarks in it. Once I run my application, all the empty bookmarks turn to squares.
We have the old license and it doesn’t work with 6.3. So I removed the lines that load the license. The InsertHtml method in the 5.2.2 seems to have some problem but it’s been fixed in 6.3.
Since 6.3 fixes something and breaks others, we are holding back renewing the license. Please let me know whether it’s because I am using evaluation copy or something else.
Thanks for your request. Could you please attach your document for testing and provide me your code? I will investigate the issue and provide you more information.
Best regards.
Thank you for additional information. There are not just bookmarks in your document there are form fields. The problem with empty form fields is logged in our defect database as issue #7770. I will notify you as soon as it is fixed.
As a workaround you can try using the following code:
// Open document
Document doc = new Document(@"Test075\in.doc");
// Do something with document
// Before saving we should remove values from empty formafields
foreach(FormField field in doc.Range.FormFields)
{
if (string.IsNullOrEmpty(field.Result))
field.Result = string.Empty;
}
// Save output document
doc.SaveToPdf(@"Test075\out.pdf");