0 Replies Latest reply on Jun 28, 2017 4:19 AM by Yong Ning

    ExtensionLineDirection and  DimensionLineDirection

    Yong Ning

      What is the difference between the ExtensionLineDirection statement and DimensionLineDirection statement.

       

       

       

      ExtensionLineDirection.jpg

       

      code is

      '

       

      Private Sub del1()

          Dim swApp As SldWorks.SldWorks, swModel As ModelDoc2

              Set swApp = Application.SldWorks

              Set swModel = swApp.ActiveDoc

          Dim SwSelMgr As SelectionMgr

              Set SwSelMgr = swModel.SelectionManager

          Dim swDispDim As DisplayDimension, swDim As Dimension

              Set swDispDim = SwSelMgr.GetSelectedObject5(1)

              With swDispDim

                   Debug.Print .Type2

                   Set swDim = .GetDimension

              End With

          Dim vDir, vDir1, Str

          Dim MathVect  As MathVector, MathVect2 As MathVector

              With swDim

                  Set MathVect = .DimensionLineDirection

                  vDir = MathVect.ArrayData

                  Str = "DimensionLineDirection is Direction ("

                  For ii = 0 To 2

                       Str = Str & vDir(ii) & ","

                  Next ii

                  Str = Left(Str, Len(Str) - 1) & ")"

                  Debug.Print Str

               

                  Set MathVect = .ExtensionLineDirection

                  vDir1 = MathVect.ArrayData

                  Str = "ExtensionLineDirection is Direction ("

                  For ii = 0 To 2

                       Str = Str & vDir1(ii) & ","

                  Next ii

                  Str = Left(Str, Len(Str) - 1) & ")"

                  Debug.Print Str

                  Stop

                  Stop

              End With

              Stop

       

       

      End Sub

       

       

       

       

       

      ------------------

      2017 SOLIDWORKS API Help - ExtensionLineDirection Property (IDimension)  http://help.solidworks.com/2017/english/api/sldworksapi/solidworks.interop.sldworks~solidworks.interop.sldworks.idimension~extensionlinedirection.html

       

       

      2017 SOLIDWORKS API Help - DimensionLineDirection Property (IDimension)  http://help.solidworks.com/2017/english/api/sldworksapi/solidworks.interop.sldworks~solidworks.interop.sldworks.idimension~dimensionlinedirection.html

       

       

      *****************************************************

       

      Get Display Dimension Type - API | SOLIDWORKS Forums  https://forum.solidworks.com/message/317119#comment-317119

      GetAttachedEntities | SOLIDWORKS Forums  https://forum.solidworks.com/message/749451#comment-749451

      Horizontal or Vertical Dimension? | SOLIDWORKS Forums  https://forum.solidworks.com/message/687424

      How to move Arrow point of Note (balloon)? | SOLIDWORKS Forums  https://forum.solidworks.com/message/757281#comment-757281

      How to determine the vertical size, or horizont... | SOLIDWORKS Forums  https://forum.solidworks.com/message/721540#comment-721540