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!

Get user Selected objects in the C# api

Status
Not open for further replies.

vlholyoak

Mechanical
Dec 30, 2009
2
I am trying to get a user selected sketch to perform actions with using the c# api. How do you get the Sketch object just by the user selecting it interactively?
 
Replies continue below

Recommended for you

You must first get the UI instance as follows:
UI userint = NXOpen.UI.GetUI();

Then the userint object has functions that will allow you to get the selected objects such as:

NXObject obj1 = userint.SelectionManager.GetSelectedObject(0);
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor