Free Support Forum - aspose.com

Update fields

Hello,


In the documentation I find that fields in a word file aren’t updated automatically.
In the 11.7 version this worked fine. However since I updated my library my fields are updated when I save my word as a pdf. (I use 11.10 now).

I attached the in and output files for your convenience.

It seems the update only happens in the header and footers. Is there a way to make sure this doesn’t happen?

greetings

Hi Annelore,


Thanks for your inquiry. In this case, please note that Aspose.Words tries to mimic the way Microsoft Word works. To you, this means that if you render a Microsoft Word document into PDF using Aspose.Words, the output will appear exactly as if it was done by Microsoft Word. To confirm this, I have attached a Pdf document, that is produced by using Microsoft Word 2007, here for your reference. If we can help you with anything else, please feel free to ask.

Best regards,

Hi Awais,


In the documentation (http://www.aspose.com/docs/display/wordsjava/Document) under the updateFields method I find the following. “When you open, modify and then save a document, Aspose.Words does not update fields automatically, it keeps them intact.
In the 11.7 release it seemed to work like this.

Otherwise is there a way to prevent these fields from being updated? Some sort of lock function on the fields?

Hi Annelore,


Thanks for the additional information. I have logged a new ticket in our bug tracking system as WORDSNET-7521. Your request has also been linked to this issue and you will be notified as soon as it is resolved. Sorry for the inconvenience.

Best regards,

Hi Annelore,


Thanks for your patience.

I’m sorry to share with you that on further investigation our development team came to know that they won’t be able to implement the fix of your issue. Your issue is closed with ‘Won’t Fix’ resolution. This means the issue is actually not fixed but closed because we can not fix this. I would suggest you please use FieldChar.IsLocked property to set whether the parent field is locked (should not recalculate its result) before rendering the document to Pdf. I hope, this helps. If we can help you with anything else, please feel free to ask.

Best regards,