Hide Table of Contents
InsertRip Method (IModelDoc2)

Creates a rip feature.

.NET Syntax

Visual Basic (Declaration) 
Sub InsertRip( _
   ByVal Gap As System.Double _
) 
Visual Basic (Usage) 
Dim instance As IModelDoc2
Dim Gap As System.Double
 
instance.InsertRip(Gap)
C# 
void InsertRip( 
   System.double Gap
)
C++/CLI 
void InsertRip( 
&   System.double Gap
) 

Parameters

Gap
Size of the gap

Remarks

The direction of the rip is determined by an encoded selection mark (see table and example).

 

 

Selection Mark

IRipFeatureData::GetDirection

This direction

16

0

Other direction

32

1

Both directions

64

2

Example

 

Option Explicit

Dim swApp As SldWorks.SldWorks

Sub main()

    Dim swModel           As SldWorks.ModelDoc2

    Dim bValue            As Boolean

    Dim lRipDirection     As Long

    Dim swFeature         As SldWorks.Feature

    Dim swRipFeatureData  As SldWorks.RipFeatureData

    ' Connect to SolidWorks

    Set swApp = Application.SldWorks

    ' Get active model

    Set swModel = swApp.ActiveDoc

    ' Clear selection

    swModel.ClearSelection2 True

    lRipDirection = 64 'See previous table

    ' Select a sketch line in the model for which no edge exists

    bValue = swModel.Extension.SelectByID2("Line1@Sketch4", "EXTSKETCHSEGMENT", -0.08287974166663, -0.05429248297937, 0, True, lRipDirection, Nothing, 0)

    ' Select two edges

    bValue = swModel.Extension.SelectByID2("", "EDGE", 0.09034940302092, 0.03401936632302, -0.0615169961092, True, lRipDirection, Nothing, 0)

    bValue = swModel.Extension.SelectByID2("", "EDGE", 0.09845029349768, -0.001543927218454, -0.06976898763294, True, lRipDirection, Nothing, 0

    ' Insert the rip feature

    swModel.InsertRip 0.0021

    ' Get inserted rip feature

    ' Assume it is the last feature in the FeatureManager design tree

    Set swFeature = swModel.FeatureByPositionReverse(0)

    ' Clear selection

    swModel.ClearSelection2 True

    Debug.Print "Rip feature: " & swFeature.Name

End Sub

 

See Also

Availability

SolidWorks 2001Plus FCS, Revision Number 10.0


Provide feedback on this topic

SOLIDWORKS welcomes your feedback concerning the presentation, accuracy, and thoroughness of the documentation. Use the form below to send your comments and suggestions about this topic directly to our documentation team. The documentation team cannot answer technical support questions. Click here for information about technical support.

* Required

 
*Email:  
Subject:   Feedback on Help Topics
Page:   InsertRip Method (IModelDoc2)
*Comment:  
*   I acknowledge I have read and I hereby accept the privacy policy under which my Personal Data will be used by Dassault Systèmes

Print Topic

Select the scope of content to print:



x

We have detected you are using a browser version older than Internet Explorer 7. For optimized display, we suggest upgrading your browser to Internet Explorer 7 or newer.

 Never show this message again
x

Web Help Content Version: API Help (English only) 2013 SP05

To disable Web help from within SOLIDWORKS and use local help instead, click Help > Use SOLIDWORKS Web Help.

To report problems encountered with the Web help interface and search, contact your local support representative. To provide feedback on individual help topics, use the “Feedback on this topic” link on the individual topic page.