0
我正在使用Word Automation从我的应用程序创建文档,并且需要将三个签名添加到文档的页脚。然而,这很容易让他们出现,因为我想不起作用。将三个对齐图像添加到word文档页脚
下面是我使用的代码:
//add initials to footer
if (oWordDoc.Sections.Count > 0) {
Range r = oWordDoc.Sections[1].Footers[WdHeaderFooterIndex.wdHeaderFooterPrimary].Range;
Object colapseDir = WdCollapseDirection.wdCollapseStart;
r.Collapse(ref colapseDir);
oWord.ActiveWindow.View.Type = WdViewType.wdPrintView;
oWord.ActiveWindow.ActivePane.View.SeekView = WdSeekView.wdSeekCurrentPageFooter;
oWord.Selection.TypeParagraph();
oWord.Selection.Paragraphs.Alignment = WdParagraphAlignment.wdAlignParagraphLeft;
oWord.ActiveWindow.Selection.Font.Name = "Arial";
oWord.ActiveWindow.Selection.Font.Size = 8;
if (!String.IsNullOrEmpty(plaintiffInitialFile)) {
r.InlineShapes.AddPicture(plaintiffInitialFile, ref oMissing, ref oTrue, ref oMissing);
}
oWord.ActiveWindow.Selection.TypeText("Plaintiff's Initals");
oWord.ActiveWindow.Selection.TypeText("\t");
if (!String.IsNullOrEmpty(plaintiffAttInitialFile)) {
r.InlineShapes.AddPicture(plaintiffAttInitialFile, ref oMissing, ref oTrue, ref oMissing);
}
oWord.ActiveWindow.Selection.TypeText("Plaintiff's Attorney's Initals");
oWord.ActiveWindow.Selection.TypeText("\t");
if (!String.IsNullOrEmpty(ekfgInitialFile)) {
r.InlineShapes.AddPicture(ekfgInitialFile, ref oMissing, ref oTrue, ref oMissing);
}
oWord.ActiveWindow.Selection.TypeText("EKFG's Initals");
}
这里是它是生产什么(我已经添加了注解)
这里就是我想要的
什么我需要做什么?