Private Sub Form_Load()
    Dim objApp As SolidEdgeFrameWork.Application
    Dim objDoc As SolidEdgeDraft.DraftDocument
    Dim objSheet As SolidEdgeDraft.Sheet
    Dim objEllipses As SolidEdgeFrameworkSupport.Ellipses2d
    Dim objEllipse1 As SolidEdgeFrameworkSupport.Ellipse2d
    Dim objLines As SolidEdgeFrameworkSupport.Lines2d
    Dim objline As SolidEdgeFrameworkSupport.Line2d
    Dim lngZorder As Long
    ' 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
    'getting the Active Sheet object
    Set objSheet = objDoc.ActiveSheet
    'Get the Lines2d object
    Set objLines = objSheet.Lines2d
    'Create a line crsoosing the ellipse
    Set objline = objLines.AddBy2Points(x1:=0.15, y1:=0.25, x2:=0.45, y2:=0.25)
    'Get ZOrder of the Line object
    lngZorder = objline.ZOrder
    'Get the Ellipses2d object
    Set objEllipses = objSheet.Ellipses2d
    'Create an ellipse2d object
    Set objEllipse1 = objEllipses.AddByCenter(xCenter:=0.3, yCenter:=0.25, _
                                              xMajor:=0.1, yMajor:=0, Ratio:=0.5, Orientation:=igGeom2dOrientClockwise)
    ' USER DISPLAY
    ' Release objects
    Set objApp = Nothing
    Set objDoc = Nothing
    Set objSheet = Nothing
    Set objEllipses = Nothing
    Set objEllipse1 = Nothing
    Set objLines = Nothing
    Set objline = Nothing
End Sub