Solid Edge FrameworkSupport Type Library
RemoveAllSegmentedStyles Method
Description
Removes all segments defined for the referenced graphic object.
Syntax
Visual Basic
Public Sub RemoveAllSegmentedStyles() 
Remarks
Removing segmented styles does not remove the geometry. Instead, it removes the linear styles applied to the graphic object defined by the segments. If a segment is blank (for example, when the linear style is null), it reappears when its segment is removed.
Example
Private Sub Form_Load()
    Dim objApp As SolidEdgeFramework.Application
    Dim objDoc As SolidEdgeDraft.DraftDocument
    Dim objSheet As SolidEdgeDraft.Sheet
    Dim objCircs As SolidEdgeFrameworkSupport.Circles2d
    Dim objCirc1 As SolidEdgeFrameworkSupport.Circle2d
    Dim objLinearSty As SolidEdgeFramework.LinearStyle
    Dim objLinearStys As SolidEdgeFramework.LinearStyles
    Dim lngCount 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 Linear styles collection object
    Set objLinearStys = objDoc.LinearStyles
    'Setting linear style
    Set objLinearSty = objLinearStys.Add(Name:="Myline1", Parent:="Hidden")
    ' Get the Circles collection object
    Set objCircs = objSheet.Circles2d
    ' Create a circle object
    Set objCirc1 = objCircs.AddByCenterRadius(x:=0.25, y:=0.25, Radius:=0.06)
    ' Create SegmentedStyles on circle object
    Call objCirc1.AddSegmentedStyle(x1:=0.27, y1:=0.17, x2:=0.3, y2:=0.25, Style:=objLinearSty)
    Call objCirc1.AddSegmentedStyle(x1:=0.16, y1:=0.2, x2:=0.23, y2:=0.19, Style:=objLinearSty)
    Call objCirc1.AddSegmentedStyle(x1:=0.35, y1:=0.3, x2:=0.27, y2:=0.31, Style:=objLinearSty)
    Call objCirc1.AddSegmentedStyle(x1:=0.25, y1:=0.31, x2:=0.19, y2:=0.25, Style:=objLinearSty)
    ' Apply RemoveAllSegmentedStyles method
    Call objCirc1.RemoveAllSegmentedStyles
    ' USER DISPLAY
    ' Release objects
    Set objApp = Nothing
    Set objDoc = Nothing
    Set objSheet = Nothing
    Set objCircs = Nothing
    Set objCirc1 = Nothing
    Set objLinearSty = Nothing
    Set objLinearStys = Nothing
End Sub
See Also

Circle2d Object  | Circle2d Members