Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

NX Journal Deselect

Status
Not open for further replies.

TheWenger

Aerospace
Apr 25, 2013
16
I'm writing a journal that applies a transparency to already selected solids. Once I run the journal though, I want to deselect the bodies. The only thing I've been able find is
Code:
theUI.SelectionManager.RemoveAllFromSelectionList
, which requires a SelectionHandle as one of the parameters. I can't hardly find anything about using a SelectionHandle and can't find a way to initialize one. Is there a way to deselect everything without having to worry about using a SelectionHandle?
 
Replies continue below

Recommended for you

That's a start. The object types I'm working with are from the DisplayableObject class which doesn't have that method though. NX doesn't like casting a DisplayableObject or a Component to a Body either.
 
Unhighlight is a method in the DisplayableObject class. It should work with all objects that inherit from DisplayableObject. I just used bodyObject as a generic variable name.

www.nxjournaling.com
 
Ahh there it goes. I was trying to apply it to an array of DisplayableObject objects and it recognizing System.Array as the superclass. I just had to apply it to each object in the array via a For loop.

Thanks much.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor