Hallo to all!
I have an assembly that belongs to my customer. Parts and subassembly have metadata written in the model, so I'm trying to use them to create my BOM list to be inserted in Annotation. I have two kind of property in each file: the first ones have the symbols ":" as pre-text before the property name, the second ones have the property name written inside commas:
Code:
----------------------------
Part/Assy = /g1/VITE_UNI5739_M16x65.2.1.1.4.1
----------------------------
Instance Attributes
----------------------------
----------------------------
Contents Attributes
----------------------------
(DB-PREF)
:FILING = :MI-FILE
:FILING = :SD-FILE
:ON-COPY = :MAINTAIN
:ON-XFORM = :MAINTAIN
:ON-SYSID-CHANGE = :MAINTAIN
:ON-MERGE = :DETACH
:ON-SPLIT = :MAINTAIN
"isi_stato_cod" = "3"
"isi_codice" = "K270445"
"isi_data_stato" = "2006/11/20 13:43:10 +01:00"
:ELID = "61400"
"isi_data_aggiornamento" = "2012/07/20 16:26:03 +02:00"
:UNIQUE_ID_STRING = "K270445"
:RICAMBIO = "-"
:VERSION = "0"
"id_elemento" = "61400"
"isi_descrizione" = "VITE_UNI5739_M16x65"
etc
etc
..
..
I modified the macro provided in the on-line help, as follows:
Code:
(defun bomattr-get-descrizione (selitem)
(let ((attr (sd-inq-item-attribute selitem "DB-PREF"
:values :attachment :contents)))
(if attr (getf attr :DENOMINAZIONE) nil)
)
)
I was able to read the property of type :SOMETHING = "value" and insert it in my BOM, but I cannot find the way to read the property of type "something_else" = "other value".
Any help to obtain this?
[Diese Nachricht wurde von cacciatorino am 12. Apr. 2015 editiert.]
Eine Antwort auf diesen Beitrag verfassen (mit Zitat/Zitat des Beitrags) IP