We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Issue with refreshing table of contents

Hello Aspose, I am software engineer working in a organisation.My organisation has aspose.word licence and we are using this for creating word documents.But right now I have a problem with generated word document in the refreshing of table of content.Can this possible to refresh table of contents automatically(without pressing alt+F9) in generated document...Please suggest as soon as possible...

Thanks
Shivam Kumar


Hi Shivam,


Thanks for your inquiry. You can update table of contents by using Document.UpdateFields. Please read following documentation link for your kind reference.
http://www.aspose.com/docs/display/wordsnet/How+to+Update+Fields

Moreover, A table of contents in a Word document can be built in a number of ways and formatted using a variety of options. The way the table is built and displayed by Microsoft Word is controlled by the field switches. You can press Alt+F9 in Microsoft Word to toggle display of field codes on or off.

Hope this answers your query. Please let us know if you have any more queries.