Solid Edge FrameworkSupport Type Library
AddByHtWdAng Method
Required Doubles that specify the coordinates of the lower left corner of the text box. The z1 argument is only specified for 3-D objects.
Required Doubles that specify the coordinates of the lower left corner of the text box. The z1 argument is only specified for 3-D objects.
Required Doubles that specify the coordinates of the lower left corner of the text box. The z1 argument is only specified for 3-D objects.
Specifies the height of the text box.
Specifies the width of the text box.
Specifies the angle of the text box with respect to the x axis.
Description
Creates a text box by specifying the origin, height, width, and angle.
Syntax
Visual Basic
Public Function AddByHtWdAng( _
   ByVal x1 As Double, _
   ByVal y1 As Double, _
   ByVal z1 As Double, _
   ByVal ht As Double, _
   ByVal wd As Double, _
   ByVal ang As Double _
) As TextBox
Parameters
x1
Required Doubles that specify the coordinates of the lower left corner of the text box. The z1 argument is only specified for 3-D objects.
y1
Required Doubles that specify the coordinates of the lower left corner of the text box. The z1 argument is only specified for 3-D objects.
z1
Required Doubles that specify the coordinates of the lower left corner of the text box. The z1 argument is only specified for 3-D objects.
ht
Specifies the height of the text box.
wd
Specifies the width of the text box.
ang
Specifies the angle of the text box with respect to the x axis.
Example
Private Sub Form_Load()
    Dim objApp As SolidEdgeFramework.Application
    Dim objDoc As SolidEdgeDraft.DraftDocument
    Dim objSheet As SolidEdgeDraft.Sheet
    Dim objTxtboxs As SolidEdgeFrameworkSupport.TextBoxes
    Dim objTxtbox As SolidEdgeFrameworkSupport.TextBox
    Dim objTxtbox1 As SolidEdgeFrameworkSupport.TextBox
    ' Report errors
    Const PI = 3.14159265358979
    ' Create/get the application with specific settings
    On Error Resume Next
    Set objApp = GetObject(, "SolidEdge.Application")
    If Err Then
        Err.Clear
        Set objApp = CreateObject("SolidEdge.Application")
        Set objDoc = objApp.Documents.Add("SolidEdge.DraftDocument")
        objApp.Visible = True
    Else
        Set objDoc = objApp.ActiveDocument
    End If
    'get the Active Sheet object
    Set objSheet = objDoc.ActiveSheet
    ' Create a TextBox object
    Set objTxtboxs = objSheet.TextBoxes
    Set objTxtbox = objTxtboxs.AddByHtWdAng(x1:=0.1, y1:=0.1, z1:=0, ht:=0.05, _
                                            wd:=0.05, ang:=PI / 2)
    objTxtbox.Text = "Test box"
    ' USER DISPLAY
    ' Release objects
    Set objApp = Nothing
    Set objDoc = Nothing
    Set objSheet = Nothing
    Set objTxtboxs = Nothing
    Set objTxtbox = Nothing
    Set objTxtbox1 = Nothing
End Sub
See Also

TextBoxes Collection  | TextBoxes Members