Hi,
When there is an existing text element, you can change the .textstyle.justification and then .rewrite and the justification is changed. When I am creating a new element, I can change the justification for the new element, but when that element is added to the file, the justification is lost.
Sub TextTest()'Active settings used for creating the text text element ActiveSettings.TextStyle.Justification = msdTextJustificationLeftTop Dim NewText As TextElement Set NewText = CreateTextElement1(Nothing, "X", Point3dZero, Matrix3dIdentity) 'Active Justification should be LeftTop NewText.TextStyle.Justification = msdTextJustificationCenterCenter NewText.TextStyle.NodeJustification = msdTextJustificationCenterCenter ActiveModelReference.AddElement NewText End Sub
The routine above sets active justification to LeftTop, creates a text element (LeftTop justification), changes the justification of that element to CenterCenter, and then adds the element to active model. The added element has the justification set to LeftTop instead of CenterCenter.
I'm not sure if I am doing something wrong, or if this is a bug. Can anyone help me out?
--Thanks,
--Robert