0 Replies Latest reply on Feb 20, 2018 7:38 AM by J. R.

    Assigning bodies to array for InsertCutSurface method

    J. R.

      Hello again,


      Sorry for asking another question in  a short span of time, but I ran into issue that is really ill-documented, and I can't find any examples or explanations that could allow me to figure it out on my own.


      I am writing a macro, and a part of that macro has to select a plane, and create a cut-with-surface feature through InsertCutSurface method, cutting only one specific body in a two-body part, even though both bodies intersect that plane. The InsertCutSurface documentation specifies that in order to specify bodie(s) to cut, I must fill the Bodies parameter with an array of bodies (in my case, just a single body). I don't know how to do that, and I can't find any examples.


      So basically, my question is, how do I assign a selected body (through SelectByID2) into an array that the InsertCutSurface method will accept, and cut that specific body only? Can you give an example of working code, please?


      Thank you!