Dimension.TextPosition
Description:
The position of the dimension text's drag point.
The position of the dimension text's drag point.
Remarks:
This property is not applicable to all dimensions. For example, it is not available for spot dimensions, multi-segments dimensions dimensions using equality formula, and when dimension style is ordinate.
If the position is not applicable, this property returns NULL and will not allow setting a value.
public XYZ TextPosition { get; set; }
// Get the current text XYZ position
XYZ currentTextPosition = dimToModify.TextPosition;
// Calculate a new XYZ position by transforming the current text position
XYZ newTextPosition = Transform.CreateTranslation(new XYZ(0.0, 1.0, 0.0)).OfPoint(currentTextPosition);
// Set the new text position
dimToModify.TextPosition = newTextPosition;
-
When setting this property: A non-optional argument was NULL