Hi,
i am using the following code for getting data form a table to a word document.
OleInPlaceVariant := OC_WdDoc.OleObject.Application;
Doc := OC_WdDoc.OleObject.Application.ActiveDocument;
R := Doc.Range(OleInPlaceVariant.Selection.End,
OleInPlaceVariant.Selection.End);
Doc.MailMerge.Fields.Add(R, FieldAsString('InsertExtFieldName'));
To be simplified the MailMerge.Fields.Add method expects 2 params.,
1) A Range obj. 2) A string
now, the problem i want to insert one field in to the header which is not
possible with the above code.
can any one help me out to insert a field into the header part of a word
document?
Thanks and Regards,
Vijay.