Solidworks二次开发—07—控制草图对象

对象|控制

Solidworks二次开发—07—控制草图对象

Get All Elements of Sketch Example (VB)

Solidwork中对草图的控制,下面的例子很详细。特征下的草图在solidwork中其实是特征的子特征,我们可以对特征进行GetFirstSubFeature、及GetNextSubFeature得到。

如果有需要大家可以从中找到对直线、弧线、圆等对象的操作。代码是solidworks的示例文件,里面充斥了debug.print,只是向用户显示程序执行的结果。

 

This example shows how to get all of the elements of a sketch.

 

'---------------------------------------------

' Preconditions: Model document is open and a sketch is selected.

' Postconditions: None

'---------------------------------------------

 

Option Explicit

Public Enum swSkSegments_e

    swSketchLINE = 0

    swSketchARC = 1

    swSketchELLIPSE = 2

    swSketchSPLINE = 3

    swSketchTEXT = 4

    swSketchPARABOLA = 5

End Enum

Sub ProcessTextFormat _

( _

    swApp As SldWorks.SldWorks, _

    swModel As SldWorks.ModelDoc2, _

    swTextFormat As SldWorks.textFormat _

)

    Debug.Print "        BackWards                    = " & swTextFormat.BackWards

    Debug.Print "        Bold                         = " & swTextFormat.Bold

    Debug.Print "        CharHeight                   = " & swTextFormat.CharHeight

    Debug.Print "        CharHeightInPts              = " & swTextFormat.CharHeightInPts

    Debug.Print "        CharSpacingFactor            = " & swTextFormat.CharSpacingFactor

    Debug.Print "        Escapement                   = " & swTextFormat.Escapement

    Debug.Print "        IsHeightSpecifiedInPts       = " & swTextFormat.IsHeightSpecifiedInPts

    Debug.Print "        Italic                       = " & swTextFormat.Italic

    Debug.Print "        LineLength                   = " & swTextFormat.LineLength

    Debug.Print "        LineSpacing                  = " & swTextFormat.LineSpacing

    Debug.Print "        ObliqueAngle                 = " & swTextFormat.ObliqueAngle

    Debug.Print "        Strikeout                    = " & swTextFormat.Strikeout

    Debug.Print "        TypeFaceName                 = " & swTextFormat.TypeFaceName

    Debug.Print "        Underline                    = " & swTextFormat.Underline

    Debug.Print "        UpsideDown                   = " & swTextFormat.UpsideDown

    Debug.Print "        Vertical                     = " & swTextFormat.Vertical

    Debug.Print "        WidthFactor                  = " & swTextFormat.WidthFactor

    Debug.Print ""

End Sub

Function TransformSketchPointToModelSpace _

( _

    swApp As SldWorks.SldWorks, _

    swModel As SldWorks.ModelDoc2, _

    swSketch As SldWorks.sketch, _

    swSkPt As SldWorks.SketchPoint _

) As SldWorks.MathPoint

    Dim swMathUtil              As SldWorks.MathUtility

    Dim swXform                 As SldWorks.MathTransform

    Dim nPt(2)                  As Double

    Dim vPt                     As Variant

    Dim swMathPt                As SldWorks.MathPoint

    

    nPt(0) = swSkPt.x:      nPt(1) = swSkPt.y:      nPt(2) = swSkPt.z

    vPt = nPt

    

    Set swMathUtil = swApp.GetMathUtility

    Set swXform = swSketch.ModelToSketchTransform

    Set swXform = swXform.Inverse

    Set swMathPt = swMathUtil.CreatePoint((vPt))

    Set swMathPt = swMathPt.MultiplyTransform(swXform)

    Set TransformSketchPointToModelSpace = swMathPt

End Function

Sub ProcessSketchLine _

( _

    swApp As SldWorks.SldWorks, _

    swModel As SldWorks.ModelDoc2, _

    swSketch As SldWorks.sketch, _

    swSkLine As SldWorks.SketchLine _

)

    Dim swStartPt               As SldWorks.SketchPoint

    Dim swEndPt                 As SldWorks.SketchPoint

    Dim swStartModPt            As SldWorks.MathPoint

    Dim swEndModPt              As SldWorks.MathPoint

    Set swStartPt = swSkLine.GetStartPoint2

    Set swEndPt = swSkLine.GetEndPoint2

    Set swStartModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swStartPt)

    Set swEndModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swEndPt)

    Debug.Print "      Start (sketch)   = (" & swStartPt.x * 1000# & ", " & swStartPt.y * 1000# & ", " & swStartPt.z * 1000# & ") mm"

    Debug.Print "      Start (model )   = (" & swStartModPt.ArrayData(0) * 1000# & ", " & swStartModPt.ArrayData(1) * 1000# & ", " & swStartModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      End   (sketch)   = (" & swEndPt.x * 1000# & ", " & swEndPt.y * 1000# & ", " & swEndPt.z * 1000# & ") mm"

    Debug.Print "      End   (model )   = (" & swEndModPt.ArrayData(0) * 1000# & ", " & swEndModPt.ArrayData(1) * 1000# & ", " & swEndModPt.ArrayData(2) * 1000# & ") mm"

End Sub

Sub ProcessSketchArc _

( _

    swApp As SldWorks.SldWorks, _

    swModel As SldWorks.ModelDoc2, _

    swSketch As SldWorks.sketch, _

    swSkArc As SldWorks.SketchArc _

)

    Dim swStartPt               As SldWorks.SketchPoint

    Dim swEndPt                 As SldWorks.SketchPoint

    Dim swCtrPt                 As SldWorks.SketchPoint

    Dim vNormal                 As Variant

    Dim swStartModPt            As SldWorks.MathPoint

    Dim swEndModPt              As SldWorks.MathPoint

    Dim swCtrModPt              As SldWorks.MathPoint

    

    Set swStartPt = swSkArc.GetStartPoint2

    Set swEndPt = swSkArc.GetEndPoint2

    Set swCtrPt = swSkArc.GetCenterPoint2

    Set swStartModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swStartPt)

    Set swEndModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swEndPt)

    Set swCtrModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swCtrPt)

    

    vNormal = swSkArc.GetNormalVector

    

    Debug.Print "      Start (sketch)   = (" & swStartPt.x * 1000# & ", " & swStartPt.y * 1000# & ", " & swStartPt.z * 1000# & ") mm"

    Debug.Print "      Start (model )   = (" & swStartModPt.ArrayData(0) * 1000# & ", " & swStartModPt.ArrayData(1) * 1000# & ", " & swStartModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      End   (sketch)   = (" & swEndPt.x * 1000# & ", " & swEndPt.y * 1000# & ", " & swEndPt.z * 1000# & ") mm"

    Debug.Print "      End   (model )   = (" & swEndModPt.ArrayData(0) * 1000# & ", " & swEndModPt.ArrayData(1) * 1000# & ", " & swEndModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      Center(sketch)   = (" & swCtrPt.x * 1000# & ", " & swCtrPt.y * 1000# & ", " & swCtrPt.z * 1000# & ") mm"

    Debug.Print "      Center(model )   = (" & swCtrModPt.ArrayData(0) * 1000# & ", " & swCtrModPt.ArrayData(1) * 1000# & ", " & swCtrModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      Radius           = " & swSkArc.GetRadius * 1000# & " mm"

    Debug.Print "      IsCircle         = " & CBool(swSkArc.IsCircle)

    Debug.Print "      Rot dirn         = " & swSkArc.GetRotationDir

End Sub

Sub ProcessSketchEllipse _

( _

    swApp As SldWorks.SldWorks, _

    swModel As SldWorks.ModelDoc2, _

    swSketch As SldWorks.sketch, _

    swSkEllipse As SldWorks.SketchEllipse _

)

    Dim swStartPt               As SldWorks.SketchPoint

    Dim swEndPt                 As SldWorks.SketchPoint

    Dim swCtrPt                 As SldWorks.SketchPoint

    Dim swMajPt                 As SldWorks.SketchPoint

    Dim swMinPt                 As SldWorks.SketchPoint

    Dim swStartModPt            As SldWorks.MathPoint

    Dim swEndModPt              As SldWorks.MathPoint

    Dim swCtrModPt              As SldWorks.MathPoint

    Dim swMajModPt              As SldWorks.MathPoint

    Dim swMinModPt              As SldWorks.MathPoint

    Set swStartPt = swSkEllipse.GetStartPoint2

    Set swEndPt = swSkEllipse.GetEndPoint2

    Set swCtrPt = swSkEllipse.GetCenterPoint2

    Set swMajPt = swSkEllipse.GetMajorPoint2

    Set swMinPt = swSkEllipse.GetMinorPoint2

    Set swStartModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swStartPt)

    Set swEndModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swEndPt)

    Set swCtrModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swCtrPt)

    Set swMajModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swMajPt)

    Set swMinModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swMinPt)

    Debug.Print "      Start (sketch)   = (" & swStartPt.x * 1000# & ", " & swStartPt.y * 1000# & ", " & swStartPt.z * 1000# & ") mm"

    Debug.Print "      Start (model )   = (" & swStartModPt.ArrayData(0) * 1000# & ", " & swStartModPt.ArrayData(1) * 1000# & ", " & swStartModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      End   (sketch)   = (" & swEndPt.x * 1000# & ", " & swEndPt.y * 1000# & ", " & swEndPt.z * 1000# & ") mm"

    Debug.Print "      End   (model )   = (" & swEndModPt.ArrayData(0) * 1000# & ", " & swEndModPt.ArrayData(1) * 1000# & ", " & swEndModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      Center(sketch)   = (" & swCtrPt.x * 1000# & ", " & swCtrPt.y * 1000# & ", " & swCtrPt.z * 1000# & ") mm"

    Debug.Print "      Center(model )   = (" & swCtrModPt.ArrayData(0) * 1000# & ", " & swCtrModPt.ArrayData(1) * 1000# & ", " & swCtrModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      Major (sketch)   = (" & swMajPt.x * 1000# & ", " & swMajPt.y * 1000# & ", " & swMajPt.z * 1000# & ") mm"

    Debug.Print "      Major (model )   = (" & swMajModPt.ArrayData(0) * 1000# & ", " & swMajModPt.ArrayData(1) * 1000# & ", " & swMajModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      Minor (sketch)   = (" & swMinPt.x * 1000# & ", " & swMinPt.y * 1000# & ", " & swMinPt.z * 1000# & ") mm"

    Debug.Print "      Minor (model )   = (" & swMinModPt.ArrayData(0) * 1000# & ", " & swMinModPt.ArrayData(1) * 1000# & ", " & swMinModPt.ArrayData(2) * 1000# & ") mm"

End Sub

Sub ProcessSketchSpline _

( _

    swApp As SldWorks.SldWorks, _

    swModel As SldWorks.ModelDoc2, _

    swSketch As SldWorks.sketch, _

    swSkSpline As SldWorks.SketchSpline _

)

    Dim vSplinePtArr            As Variant

    Dim vSplinePt               As Variant

    Dim swSplinePt              As SldWorks.SketchPoint

    Dim swSplineModPt           As SldWorks.MathPoint

    

    vSplinePtArr = swSkSpline.GetPoints2

    For Each vSplinePt In vSplinePtArr

        Set swSplinePt = vSplinePt

        Set swSplineModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swSplinePt)

    

        Debug.Print "      Spline (sketch)  = (" & swSplinePt.x * 1000# & ", " & swSplinePt.y * 1000# & ", " & swSplinePt.z * 1000# & ") mm"

        Debug.Print "      Spline (model )  = (" & swSplineModPt.ArrayData(0) * 1000# & ", " & swSplineModPt.ArrayData(1) * 1000# & ", " & swSplineModPt.ArrayData(2) * 1000# & ") mm"

    Next vSplinePt

End Sub

Sub ProcessSketchText _

( _

    swApp As SldWorks.SldWorks, _

    swModel As SldWorks.ModelDoc2, _

    swSketch As SldWorks.sketch, _

    swSkText As SldWorks.SketchText _

)

    Dim vCoordPt                As Variant

    Dim swMathUtil              As SldWorks.MathUtility

    Dim swXform                 As SldWorks.MathTransform

    Dim swCoordModPt            As SldWorks.MathPoint

    

    vCoordPt = swSkText.GetCoordinates

    

    Set swMathUtil = swApp.GetMathUtility

    Set swXform = swSketch.ModelToSketchTransform

    Set swXform = swXform.Inverse

    Set swCoordModPt = swMathUtil.CreatePoint((vCoordPt))

    Set swCoordModPt = swCoordModPt.MultiplyTransform(swXform)

    Debug.Print "      Coords (sketch)  = (" & vCoordPt(0) * 1000# & ", " & vCoordPt(1) * 1000# & ", " & vCoordPt(2) * 1000# & ") mm"

    Debug.Print "      Coords (model )  = (" & swCoordModPt.ArrayData(0) * 1000# & ", " & swCoordModPt.ArrayData(1) * 1000# & ", " & swCoordModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      Use doc fmt      = " & swSkText.GetUseDocTextFormat

    Debug.Print "      Text             = " & swSkText.text

    

    ProcessTextFormat swApp, swModel, swSkText.GetTextFormat

End Sub

Sub ProcessSketchParabola _

( _

    swApp As SldWorks.SldWorks, _

    swModel As SldWorks.ModelDoc2, _

    swSketch As SldWorks.sketch, _

    swSkParabola As SldWorks.SketchParabola _

)

    Dim swApexPt                As SldWorks.SketchPoint

    Dim swStartPt               As SldWorks.SketchPoint

    Dim swEndPt                 As SldWorks.SketchPoint

    Dim swFocalPt               As SldWorks.SketchPoint

    Dim swApexModPt             As SldWorks.MathPoint

    Dim swStartModPt            As SldWorks.MathPoint

    Dim swEndModPt              As SldWorks.MathPoint

    Dim swFocalModPt            As SldWorks.MathPoint

    Set swApexPt = swSkParabola.GetApexPoint2

    Set swStartPt = swSkParabola.GetStartPoint2

    Set swEndPt = swSkParabola.GetEndPoint2

    Set swFocalPt = swSkParabola.GetFocalPoint2

    Set swApexModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swApexPt)

    Set swStartModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swStartPt)

    Set swEndModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swEndPt)

    Set swFocalModPt = TransformSketchPointToModelSpace(swApp, swModel, swSketch, swFocalPt)

    Debug.Print "      Apex  (sketch)   = (" & swApexPt.x * 1000# & ", " & swApexPt.y * 1000# & ", " & swApexPt.z * 1000# & ") mm"

    Debug.Print "      Apex  (model )   = (" & swApexModPt.ArrayData(0) * 1000# & ", " & swApexModPt.ArrayData(1) * 1000# & ", " & swApexModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      Start (sketch)   = (" & swStartPt.x * 1000# & ", " & swStartPt.y * 1000# & ", " & swStartPt.z * 1000# & ") mm"

    Debug.Print "      Start (model )   = (" & swStartModPt.ArrayData(0) * 1000# & ", " & swStartModPt.ArrayData(1) * 1000# & ", " & swStartModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      End   (sketch)   = (" & swEndPt.x * 1000# & ", " & swEndPt.y * 1000# & ", " & swEndPt.z * 1000# & ") mm"

    Debug.Print "      End   (model )   = (" & swEndModPt.ArrayData(0) * 1000# & ", " & swEndModPt.ArrayData(1) * 1000# & ", " & swEndModPt.ArrayData(2) * 1000# & ") mm"

    Debug.Print "      Focal (sketch)   = (" & swFocalPt.x * 1000# & ", " & swFocalPt.y * 1000# & ", " & swFocalPt.z * 1000# & ") mm"

    Debug.Print "      Focal (model )   = (" & swFocalModPt.ArrayData(0) * 1000# & ", " & swFocalModPt.ArrayData(1) * 1000# & ", " & swFocalModPt.ArrayData(2) * 1000# & ") mm"

End Sub

 

 

Sub main()

    Dim sSkSegmentsName(5)      As String

    Dim swApp                   As SldWorks.SldWorks

    Dim swModel                 As SldWorks.ModelDoc2

    Dim swSelMgr                As SldWorks.SelectionMgr

    Dim swFeat                  As SldWorks.feature

    Dim swSketch                As SldWorks.sketch

    Dim vSkSegArr               As Variant

    Dim vSkSeg                  As Variant

    Dim swSkSeg                 As SldWorks.SketchSegment

    Dim swSkLine                As SldWorks.SketchLine

    Dim swSkArc                 As SldWorks.SketchArc

    Dim swSkEllipse             As SldWorks.SketchEllipse

    Dim swSkSpline              As SldWorks.SketchSpline

    Dim swSkText                As SldWorks.SketchText

    Dim swSkParabola            As SldWorks.SketchParabola

    Dim vID                     As Variant

    Dim i                       As Long

    Dim bRet                    As Boolean

    

    sSkSegmentsName(swSketchLINE) = "swSketchLINE"

    sSkSegmentsName(swSketchARC) = "swSketchARC"

    sSkSegmentsName(swSketchELLIPSE) = "swSketchELLIPSE"

    sSkSegmentsName(swSketchSPLINE) = "swSketchSPLINE"

    sSkSegmentsName(swSketchTEXT) = "swSketchTEXT"

    sSkSegmentsName(swSketchPARABOLA) = "swSketchPARABOLA"

    

    

    Set swApp = Application.SldWorks

    Set swModel = swApp.ActiveDoc

    Set swSelMgr = swModel.SelectionManager

    Set swFeat = swSelMgr.GetSelectedObject5(1)

    Set swSketch = swFeat.GetSpecificFeature

    

    Debug.Print "Feature = " & swFeat.Name & " [" & swSketch.Is3D & "]"

    Debug.Print "  Sketch Segments:"

    

    vSkSegArr = swSketch.GetSketchSegments

    For Each vSkSeg In vSkSegArr

        Set swSkSeg = vSkSeg

        

        vID = swSkSeg.GetId

        Debug.Print "    ID = [" & vID(0) & "," & vID(1) & "]"

        Debug.Print "      Type             = " & sSkSegmentsName(swSkSeg.GetType)

        Debug.Print "      ConstGeom        = " & swSkSeg.ConstructionGeometry

    

        Select Case swSkSeg.GetType

            Case swSketchLINE

                Set swSkLine = swSkSeg

                

                ProcessSketchLine swApp, swModel, swSketch, swSkLine

            

            Case swSketchARC

                Set swSkArc = swSkSeg

            

                ProcessSketchArc swApp, swModel, swSketch, swSkArc

            

            Case swSketchELLIPSE

                Set swSkEllipse = swSkSeg

                

                ProcessSketchEllipse swApp, swModel, swSketch, swSkEllipse

            

            Case swSketchSPLINE

                Set swSkSpline = swSkSeg

                

                ProcessSketchSpline swApp, swModel, swSketch, swSkSpline

            

            Case swSketchTEXT

                Set swSkText = swSkSeg

                

                ProcessSketchText swApp, swModel, swSketch, swSkText

            

            Case swSketchPARABOLA

                Set swSkParabola = swSkSeg

                

                ProcessSketchParabola swApp, swModel, swSketch, swSkParabola

                

            Case Default

                Debug.Assert False

        End Select

    Next vSkSeg

End Sub

'---------------------------------------------

时间: 2024-12-26 01:39:45

Solidworks二次开发—07—控制草图对象的相关文章

sw二次开发-Solidworks二次开发,控制电机旋转

问题描述 Solidworks二次开发,控制电机旋转 在solidworks中的simulation中可以完成电机对滚球丝杠的控制, 现在我想知道能不能通过solidworks的二次开发,通过VB编写程序完成精确控制电机的转速,角位移等. 可通过以下两步来实现,但现在在第二步卡住了: 1.VB发送数据给Solidworks 2.通过SOlidworks上的API来控制电机起停,转过多少度,以及转速... 尤其是第二个步求相关资料,不胜感激. 谢谢大家了,学生一枚,以上功能是论文中的一部分,我尝试

solidworks二次开发-01-录制一个宏

solidworks二次开发-01-录制一个宏 第一步: 我们需要自己录制一个宏,然后看看程序产生了什么代码.当初学习excel时候就是这么干的.只是,solidworks要复杂一些,直接录制的宏不能使用,需要做一些调整.在没有经验的时候我们最好按照下面的建议来做.  Edit or Debug SolidWorks Macro   Edit or debug SolidWorks macros using Microsoft VBA.   使用Microsoft VBA编辑或调试宏 To ed

solidworks二次开发-02-用来访问特征的两个API

访问|来访 solidworks二次开发-02-用来访问特征的两个API 来学习两个api: SelectByID2和GetSelectedObject5.这两个函数,第一个通过给出对象的name选择对象.第二个通过启用程序前已经选择的索引得到对象. 看下面程序: Option Explicit Dim swApp As SldWorks.SldWorks Dim Model As ModelDoc2 Dim feature As feature Dim boolstatus As Varian

solidworks二次开发-03-访问特征数据

访问|数据 solidworks二次开发-03-访问特征数据 'coder arden 'filename : getchoosed.swp'date  :2005-03-22'used to get the simple hole infomation dep & dia'finished lucky !!'------------------------------------------------------------ Option ExplicitDim swApp As SldWo

Solidworks二次开发—06—在装配体中添加配合

Solidworks二次开发-06-在装配体中添加配合     折腾了三天终于完成了计划中的功能模块.在一个装配体中自动判断插入合适的零件,并添加配合. 在前面几篇文章中我已经基本上说明了如何得到零部件的数据信息.如何插入零部件.如何得到已经选择的特征等. 下面只介绍怎样进行配合 在做配合时,需要经常选择到零件的面.线等,这是一个问题,还有就是介绍一下addmate2函数的使用: 一般进行配合我们按照下面的次序来进行:     1-ModelDoc.ClearSelection2  '取消所有选

Solidworks二次开发-05-装配体中插入零部件

插入 Solidworks二次开发--装配体中插入零部件     在往装配体中插入零部件时,我们使用addcomponent 函数.如果需要选定零部件的配置,则需要使用addcomponent4. 先学习下语法:   addcomponent4: retval = AssemblyDoc.AddComponent4 ( compName, configName, x, y, z)   Input:         (BSTR) compName                    Path n

solidworks二次开发-04-修改数据

数据 solidworks二次开发-04-修改数据 上次已经可以访问特征的各参数了,今天我们来修改它: 要修改前面的步骤不能少,当我们已经可以读取一些特征时,我们就可以给他设定一些值.当然有时需要调用特定的参数.solidworks是ole和com的,所以要习惯这样. 在修改完特征后需要调用函数modifydefinition()来实现变化. 我们给一个例子,这个例子比前面的都要全面,它有很好的容错引导机制,可以直接拿来成为一个稳定的宏程序. This example doubles the l

Solidworks二次开发—08--判断是什么特征

得到了一个特征feature,怎么判断是那种呢? 如果我们定义了一个特征对象: dim curfeature as sldworks.feature 然后又通过SelectMgr得到了这个特征,然后可以使用feature.GetTypeName来判断是那种: Select Case curfeature.GetTypeName Case "Cut"       '一个拉伸切除特征 do sth. Case "HoleWzd"  '一个异型孔特征 do sth. Ca

solidworks二次开发--11--开始总体了解

经过了上面的几个练兵之后,对solidworks的对象模型应该有了一个大体的了解,程序的运行机制也清晰了.慢慢的会越来越容易驾驭.下面的几个图片链接是solidworks的对象模型.作为参考,好在需要一种功能或者想要控制一个功能时不知道api藏在那里: 总体结构:site=mblogger 零件结构:site=mblogger 装配体结构:site=mblogger 工程图结构:site=mblogger 特征结构:site=mblogger 注释结构:site=mblogger 工程图注释结构