Cancel
Showing results for 
Search instead for 
Did you mean: 

Clone toolpath and save in UDO

Creator
Creator

Hello,

I am currently developing a NX plugin using C#. I want to clone a toolpath in an operation as reference and save in UDO or create a link in UDO. So that I can get the duplicated toolpath from the UDO when I reopen the plugin. My question is:

  1. Is there a method to clone/duplicate a toolpath?
  2. Which mehod can be used to set/get a toolpath object as attribute in UDO?
  3. If set the duplicated toolpath as a link for the UDO, how to save the duplicated toolpath in the work part?

 

Thanks

reilley

NX v10.0.3.5MP4

3 REPLIES

Re: Clone toolpath and save in UDO

Pioneer
Pioneer

Hi 

 

b)

The Geometry can be linked directly with UDO. Just set the Link and retrieve the link whereever needed.

 

UserDefinedObject.LinkDefinition[] UDOLinks = UDO.GetLinks(UserDefinedObject.LinkType.Type1);

BeamUDO.SetLinks(UserDefinedObject.LinkType.Type1, UDOLinks );

 

Thanks

Gunjeet

Re: Clone toolpath and save in UDO

The path API allows to access to the path and to create a path, but it is on an operation. One of the ways to keep the path as a backup would be to create a User Defined operation in the unused group in all views, and then retain the name of that UDOP in the one which wants to use the path. It is a loose connection but it is possible to do this. It is not very elegant but will work.

Understanding the intent of what you are trying to do would help in making any kind of a recommendation (and we might also be able to say what the limitations might be). 

 

Mark Rief
Retired Siemens

Re: Clone toolpath and save in UDO

Creator
Creator

It works though it is a bit ugly Smiley Wink.
Thanks!