Submitted by pushpendra sharma on Thu, 03/17/2016 - 23:54
Forums:
i have a assembly structure .i need to generate mid surface for each component and then translate the assy FILE into a parasolid at run time.
i have a assembly structure .i need to generate mid surface for each component and then translate the assy FILE into a parasolid at run time.
re: midsurface
What NX command do you currently use to create the midsurfaces?
i am using builder class for
i am using builder class for mid surface.i have a assy file and need to collect all the solid bodies of each component and extract their mid surface by using builder class.builder class need a body tyoe arguments and i have full components list so for now i need to collect the solid bodies of each child part in assy and then extract a mid surface for each
Dim midSurfaceByFacePairsBuilder1 As NXOpen.Features.MidSurfaceByFacePairsBuilder
midSurfaceByFacePairsBuilder1
=workPart.Features.CreateMidSurfaceByFacePairsBuilder(nullNXOpen_Features_Feature)
Pushpendra Sharma
KBE & Customization
re: midsurfaces
If you have a reference to a component, you can get a reference to the part object. Once you have a reference to the part, you can iterate through the .Bodies collection to get the solid bodies of interest.
Dim myComponent as Assemblies.Component
myComponent = {some component}
dim myPart as Part = myComponent.Prototype.OwningPart
for each tempBody as body in myPart.Bodies
'do something
next