0
using word = Microsoft.Office.Interop.Word;

How do I add an image at a specific co-ordinate of the Word documents.

I have been searching for a while, but unsuccessful in finding a solution for this problem.

EDIT Currently using :

    oDoc.Application.Selection.InlineShapes.AddPicture(@"C:\Users\MHD\Desktop\retouche.bmp");
    oDoc.Application.Selection.MoveDown(word.WdUnits.wdScreen, 2);

Problem:

enter image description here

What is needed:

enter image description here

So the image should be located at the bottom right corner of the last page in the document.

Khalid Farhan
  • 435
  • 1
  • 3
  • 19

2 Answers2

1

one way to do that is:

  • open your word document > add a bookmark named: "PicHere"

  • and then check this link

Community
  • 1
  • 1
tgondar
  • 184
  • 4
  • 10
1

Instead of inserting a inline shape which is positioned within the text. You may want to insert as a normal shape, which can be positioned anywhere above the text:

oDoc.Application.ActiveDocument.Shapes.AddPicture(
    @"C:\Users\MHD\Desktop\retouche.bmp",
    null, null,
    left, top, width, height)
Xiaoy312
  • 14,292
  • 1
  • 32
  • 44