Position of image aspose.words

Hello,

I wanted my image when replacing the wildcard to be on the X 0 axis, and not in the middle of the document as it is currently, could you help me?

code.docx (5.8 KB)
before.docx (10.7 KB)
after.docx (10.7 KB)

@anemam Based on your code, the simplest way to change the position of the image is to set the desired Left property of the Shape that is generated when the image is inserted in the replace method. For example:

...
Shape img = builder.InsertImage(_image);
img.Left = 0;
...

Working!!

Thank you

1 Like