Showing results for 
Search instead for 
Do you mean 
Reply

Is there a way to automatically add "non-component" references when using UFClone?

[ Edited ]

Hi everyone,

 

I'm writing a tool that uses the NX UFClone functions to clone an assembly but I have come across  a problem. The problem is that when adding a part that has interpart expressions, it does not add the referenced parts. I would have just accepted that fact as a limitation of NX, but I noticed the following in uf_clone.h.

 

 

enum UF_CLONE_notify_cb_e
{
    ...
UF_CLONE_beg_assy_nc_load_cb, /* called when an assembly just added to
the clone operation,*/ UF_CLONE_end_assy_nc_load_cb, /* is about to start having non-component refs of its components added */

 

What does it consider "non-component refs"? In what situation would that callback be called?

 

Also, does anyone know if there is an API to replicate the behavior of ug_edit_part_names.exe -list?

 

Any help is much appreciated.

 

Thanks,

Peter

2 REPLIES

Re: Is there a way to automatically add "non-component" references when using UFClone?

[ Edited ]

"Also, does anyone know if there is an API to replicate the behavior of ug_edit_part_names.exe -list?"

 

One way would be to use the ug_edit_part_names.exe directly. Your program could spawn a process, pass the desired arguments, then parse the stdout and stderr streams for the information. Here is a journal that calls the ug_convert_part program; calling ug_edit_part_names would be similar.

Re: Is there a way to automatically add "non-component" references when using UFClone?

Thanks, that is what I have decided to do.