1 Reply Latest reply on Jul 3, 2018 8:09 AM by Fifi Riri

    Solidworks API for System/Options/Tangent Edges

    Michele Vergine

      Hi everyone,

      i tried to use this ISldWorks::GetUserPreferenceIntegerValue(swUserPreferenceIntegerValue_e.swEdgesTangentEdgeDisplay)

      but it seems, when in drawing,  not getting correct values.

      For example this is my current setting

      When i call la getUserPreferences(swUserPreferenceIntegerValue_e.swEdgesTangentEdgeDisplay)

      i get value = 1

      that means visible....

      What i have to do to access the correct value?????


        • Re: Solidworks API for System/Options/Tangent Edges
          Fifi Riri


          I believe swEdgesTangentEdgeDisplay is for the Part display

          For the drawing it's swTangentEdgeDisplayDefault


          This code will set the default parameter of the tangent edges of the drawings to "visible"


          Sub main()

              Dim swApp As SldWorks.SldWorks

              Set swApp = Application.SldWorks

              Debug.Print swApp.GetUserPreferenceIntegerValue(swUserPreferenceIntegerValue_e.swTangentEdgeDisplayDefault)

              boolstatus = swApp.SetUserPreferenceIntegerValue(swUserPreferenceIntegerValue_e.swTangentEdgeDisplayDefault, swDisplayTangentEdges_e.swTangentEdgesVisible)

              Debug.Print swApp.GetUserPreferenceIntegerValue(swUserPreferenceIntegerValue_e.swTangentEdgeDisplayDefault)

          End Sub


          Values returned:

          0 for swTangentEdgesHidden

          1 for swTangentEdgesVisibleAndFonted

          2 for swTangentEdgesVisible