Add a PAGEREF field to a DOCX and specify its options

DOCX PDF C# VB