2 Replies Latest reply on Jul 11, 2014 9:04 AM by Sushil Chaskar

    Parting line Algorithm

    Sushil Chaskar

      Hi.. Actually I am starting to work on code that will get best possible parting line and show on the model.. Can you guys please suggest as to how should I proceed with the algo..?

        • Re: Parting line Algorithm
          Ar K

          Hi :-)

          Are You work in Mold Design Field ?

          What is your problem ?




          VB.net example :


                  Dim swDoc As ModelDoc2 = Nothing

                  Dim swPart As PartDoc = Nothing

                  Dim swDrawing As DrawingDoc = Nothing

                  Dim swAssembly As AssemblyDoc = Nothing

                  Dim boolstatus As Boolean = False

                  Dim longstatus As Integer = 0

                  Dim longwarnings As Integer = 0


                  swDoc = swApp.ActiveDoc



                  boolstatus = swDoc.Extension.SelectByID2("Parting Line1", "BODYFEATURE", 0, 0, 0, False, 0, Nothing, 0)

                  Dim swSelectionMgr As SelectionMgr = swDoc.SelectionManager

                  Dim PLFeat As Feature = swSelectionMgr.GetSelectedObject6(1, -1)


                  Dim swPartingLine As PartingLineFeatureData = PLFeat.GetDefinition


                  Dim i As Int16 = swPartingLine.GetPartingLinesCount


                  Dim edgVar() As Object

                  edgVar = swPartingLine.PartingLines


                  Dim edg(edgVar.Length - 1) As Edge

                  For j As Integer = 0 To edg.Length - 1

                      edg(j) = edgVar(j)



                  Dim x As Double = edg(0).IGetStartVertex.GetPoint(0)