How to programmatically change the layout of a Word 2010 document?

We have an application that reads Word documents and imports them into our file format.

A recent error was discovered that the number of pages is only available in the page layout view, but Word 2010 is used by default in the website layout.

Using .NET C #, how can we change the view to return the page count to us?

+3
source share
1 answer

I believe that the property you are looking for Document.ActiveWindow.View.Type = wdPrintView;can be read more on this MSDN .

+8
source

Source: https://habr.com/ru/post/1777894/


All Articles