#Define wdHeaderFooterPrimary 1 #Define wdHeaderFooterFirstPage 2 #Define wdHeaderFooterEvenPages 3 oWord = Createobject('Word.Application') With oWord .Documents.Add With .ActiveDocument.Sections(1) .Headers(wdHeaderFooterPrimary).Range.Text = "This is header" .Footers(wdHeaderFooterPrimary).Range.Text = "This is footer" .Footers(wdHeaderFooterPrimary).PageNumbers.Add Endwith .Visible = .T. .Activate EndwithCetin