krz177
Mechanical
- Jan 11, 2015
- 14
Run into a problem with using the curve collector in the snap block based dialog. When prompted to select a curve and I select one, a linked composite curve appears in the part navigator of the workpart as desired. As soon as I hit OK on the dialog the linked composite curve feature disappears. I am used to the regular NXOpen builders with having to commit an object and I don't see that same functionality in the snap wrapped functions.
I hacked together a workaround that "works" but is very flawed. I basically found the composite curve feature in the tree (all within the OnOK sub) linked it to a composite curve builder, did a commit() and dispose() on the object, and like that a linked composite curve is now a feature in my part navigator.
I realize that this method is not correct and that this should work using the code below but I can't seem to get the linked composite curve feature to stay otherwise. Combed through countless documentation and still turning up empty. Any insights on what I'm missing?
Thanks in advance
I hacked together a workaround that "works" but is very flawed. I basically found the composite curve feature in the tree (all within the OnOK sub) linked it to a composite curve builder, did a commit() and dispose() on the object, and like that a linked composite curve is now a feature in my part navigator.
I realize that this method is not correct and that this should work using the code below but I can't seem to get the linked composite curve feature to stay otherwise. Combed through countless documentation and still turning up empty. Any insights on what I'm missing?
Code:
curveCollector.AllowMultiple = True
curveCollector.CurveRules = 4
curveCollector.EntityType = 4
curveCollector.InterpartSelection = Snap.UI.Block.InterPartSelectionCopy.Controlled
curveCollector.CreateInterpartLink = True
Me.AddBlocks(curveCollector)
Thanks in advance