0
Answer

wdFieldNumPages does not match total pages!

Luke

Luke

15y
3.8k
1
Hi! I generated a Word document from a template and I added the field concerning the total pages, but the number of it does not match the real amount when I open the document. I add the field in this way (C#): Object oMissing = System.Type.Missing; Object total = Word.WdFieldType.wdFieldNumPages; range.Fields.Add(range, ref total, ref oMissing, ref oMissing); If you need more information about it to know if there is any kind of error or something, just tell me (I'm a little bit a newbie about this)! Thanks in advance!