问题
I would like to use Microsoft.Office.Interop.Word to programatically remove all line numberings from a Word document. (How) is it possible?
Should I use the LineNumbering interface?
回答1:
Line numbering is an document- or section-level setting, and it's controlled over the PageSetup
object. To simply turn it off throughout the document:
Word.Document doc = wdApp.ActiveDocument;
doc.PageSetup.LineNumbering.Active = false;
来源:https://stackoverflow.com/questions/49496067/is-it-possible-to-use-microsoft-office-interop-word-to-programatically-remove-li