How to create a table heading for each new page using Word interop?

I am trying to create a table with a title. I want this title to be repeated for every new page that the table accepts. How can I do this in C # with Word 2007 Interop?

+3
source share
2 answers
Microsoft.Office.Interop.Word.Table table;
/* ... */
table.Rows[1].HeadingFormat = -1;
+11
source

This is what the word is for me, Loop through each table at the end

            foreach (Table item in doc.Tables)
            {
                item.Rows[1].HeadingFormat = -1;
                item.ApplyStyleHeadingRows = true;
            }

and style for each table with a set of properties to create a title for each new

                    t.set_Style(TableStyle);
0
source

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


All Articles