We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

TextBox Vertical Alignment & Position Problems

I am attempting to resize and reposition an existing fixed positioned text box however I’m having difficulties with:

  • 1. Determining vertical position (for example, top or bottom)
  • 2. Changing the text box position

Background

I have textboxes that have fixed position and have vertical alignment set to either top or bottom. During an image mail merge, I find the owning textbox for the mail merge field and then resize and reposition the text box based on the image size.

1. Vertical Alignment

How do I determine the text box vertical alignment as seen through the Format Shape dialog in Microsoft Word?

For example, the attached file contains image of document layout wherePHOTO_PATH2 merge field is within a text box that has its vertical alignment set to Bottom.

Through the non-public Shape property, I see the TextVerticalAlignment property is set as I expect:

textBox.TextBoxFormat.TextVerticalAlignment == VerticalAlignment.Bottom

However, I expected to use textBox.TextBoxFormat.VerticalAlignment property however it is always ‘None’:

textBox.TextBoxFormat.VerticalAlignment == ShapeVerticalAlignment.None

2. TextBox Position

When adjusting the position of the text box, I expected to use the properties

textBox.TextBoxFormat.HorizontalPosition

textBox.TextBoxFormat.VerticalPosition

I found that these properties are saved however they are not reflected in the document when opened with Microsoft Word.

It appears that using the non-public Shape property does work as expected however it is not public:

textBox.Shape.HorizontalPosition

textBox.Shape.VerticalPosition

Attachment: DocumentLayout_b19494af.zip


2 Replies

PR Poorani Rajendran Syncfusion Team August 9, 2019 02:10 PM UTC

Hi Jason,

Thank you for contacting Syncfusion support.

We can reproduce the reported textbox position and alignment issue from our side. We will validate on this issue and update you the further details on 14th August, 2019

Regards,
Poorani Rajendran



PR Poorani Rajendran Syncfusion Team August 14, 2019 12:04 PM UTC

Hi Jason,

Thank you for your patience.

We have confirmed that the reported textbox position and alignment issue is a defect and we have logged a defect report.

The fix for this issue will be included in our 2019 Volume 3 release which is expected to be available at the end of September, tentatively.

Please let us know if you have any other questions.

Regards,
Poorani Rajendran


Loader.
Live Chat Icon For mobile
Up arrow icon