AlterLines.AddTextDef method

AutoCAD Map 3D ActiveX

AlterLines.AddTextDef method

Adds a text alteration to the property alteration definition.

AddTextDef( _
 TextValue As String, _
 Height As String, _
 InsertPoint As String, _
 Justification As String, _
 TextStyle As String, _
 Layer As String, _
 Color As String, _
 Rotation As String _
 ) As TextDef

Returns a text definition.

TextValue

Text value or expression

Height

Text height or expression

InsertPoint

The location for insertion of the text or expression

Justification

Text alignment or expression

Text Style

Text style or expression

Layer

Layer where the text is drawn or expression

Color

Text color or expression

Rotation

Text rotation or expression

This example builds on sample code for altering queried objects. For more information, click . The following code adds a text entity in Arial font that is larger than the text created by the original sample code. Comment out the call to Alterlines.Add in the sample and add the call to Alterlines.AddTextDef as shown here:

'Set txtdf = altls.Add( _

' kAlterationTextEntity, _

' ":NAME@WATER_BODIES")

Set txtdf = altls.AddTextDef(":NAME@WATER_BODIES", "200", _

".LABELPT", "CENTER", "Arial", "Water", "Bylayer", "0")