IntelliCAD 11.1 Object Library | |
InsertionPoint Property | |
See Also |
MText Object : InsertionPoint Property |
Description
Property type
Syntax
Visual Basic |
---|
Public Property InsertionPoint As Point |
Example
Private Sub InsertionPoint_Example()
' This example creates text and adds it to the drawing using the
' AddText method. It then obtains the InsertionPoint and TextAlignmentPoint properties.
Dim icadDoc As IntelliCAD.Document
Dim myText As String
Dim textObj As IntelliCAD.Text
Dim insPt As IntelliCAD.Point
Dim height As Double
Set icadDoc = ActiveDocument
Set insPt = Library.CreatePoint(0, 9)
height = 5
myText = "Test string for the AddText method"
' Add the Text object
Set textObj = icadDoc.ModelSpace.AddText(myText, insPt, height)
textObj.Update
ThisDocument.Application.ZoomCenter insPt, 20
MsgBox "Insertion Point: " & Chr(13) & "x = " & textObj.InsertionPoint.x & Chr(13) & "y = " & textObj.InsertionPoint.y & Chr(13) & "z = " & textObj.InsertionPoint.z
MsgBox "Text Alignment Point: " & Chr(13) & "x = " & textObj.TextAlignmentPoint.x & Chr(13) & "y = " & textObj.TextAlignmentPoint.y & Chr(13) & "z = " & textObj.TextAlignmentPoint.z
End Sub