Adjust the text and picture vertical alignment whenRVF Export Docx
Posted: Sat Oct 14, 2017 6:51 am
I set the picture's valign = absMiddle, the displaying effect is perfect. But it will be changed to according to baseline after it is exported to docx, and I must open the docx and change the alignment property again with vba(comobject).Can u provide the saveAs Docx vertical alignment option or give me any advice?
This is my code to adjust the alignment:
This is my code to adjust the alignment:
Code: Select all
uses WordXp;
var wordDoc:TWordDocument;
begin
..............
wordDoc.Select; //Select all
wordDoc.Application.Selection.ParagraphFormat.BaseLineAlignment := 1; //set valign absMiddle
wordDoc.Application.Selection.SetRange(0,0);//Deselect
end;