Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

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

Edit attribute without open NX files

Status
Not open for further replies.

cubalibre000

Mechanical
Joined
Jan 27, 2006
Messages
1,070
Location
IT
Hi,
it's possible via programming to create or delete or edit NX attribute without open the files ?
If yes, which is the code or the command to use ?

Thank you...

Using NX 8 and TC9.1
 
Yes, is possible to read, edit, delete atributes in batch mode, but, the script need open the file in background.
 
You may also want to consider this NX open function for reading attributes.

(from the T-docs)

UF_ATTR_ask_part_attrs_in_file

Defined in: uf_attr.h

Overview

Reads all the part attributes from a part file without requiring that the
part be opened. The values returned are always those stored on disk
even if the part is currently loaded in memory (use
UF_ATTR_ask_part_attrs for such a part). This routine is normally
considerably more efficient than opening the part and finding the part
attribute.

Environment

Internal and External


See Also

UF_ATTR_part_attr_s

Required License(s)

gateway

int UF_ATTR_ask_part_attrs_in_file
(

const char * part_name,
int * n_attributes,
UF_ATTR_part_attr_p_t * attributes

)

const char * part_name Input Part file name to read part attributes from or
part name when using NX Manager (internal name).
int * n_attributes Output Count of attributes returned.
UF_ATTR_part_attr_p_t * attributes Output to UF_*free* Allocated array of structures holding
attribute titles and values. This must
be freed by the caller using UF_free.

If a returned attribute type is UF_ATTR_string or
UF_ATTR_reference then the string returned
was dynamically allocated and you must use
UF_free to deallocate the memory.

If a returned attribute type is UF_ATTR_time, then
the value will be in the current time zone of the
machine on which the program is being executed.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top