I have a set code for the current page.
VAR
MMM, NNN, AAA: Olevariant;
Begin
mmm: = wdLine; nnn: = 1; aaa: = wdFieldPage; WordApp.ActiveWindow.ActivePane.View.SeekView: = wdSeekCurrentPageHeader; WordApp.Selection.Move (mmm, nnn); WordApp.Selection.ParagraphFormat.Alignment: = wdAlignParagraphCenter;
Wordapp.selection.insertafter ('first'); mmm: = WDCharacter; Wordapp.Selection.move (MMM, NNN); Wordapp.Selection.RANGELDS.ADD (Wordapp.Selection.Range, AAA, MMM, NNN); AAA: = WordApp.Selection.Insertafter ('page / first'); Wordapp.Selection.Move (MMM, NNN); Wordapp.selection.fields.add (Wordapp.Serection.Range, AAA, MMM, NNN);
Wordapp.Selection.InsertAfter ('page'); WordApp.activeWindow.ActivePane.View.seekview: = wdseekmainDocument;
END;
However, only the first page, how to modify the header of the page behind?