![]() |
#1
|
|||
|
|||
BOM issue
We run against some problems for the BOM and BOM flags in annotation, we are trying to explain everything to PTC, but it takes a long time.
So I want to create my own “current bom” in annotation with all the necessary data I’ll find in windchill also by a small customization. I already know that there 3 tables in annotator (drafting) that should be filled. 'Docu_bom_ic_sysids_ltab' 'Docu_am_bom_comp_ltab' 'Docu_current_bom_posno_ltab' I can fill these tables with the necessary data with some annotator commands. There is also a table in annotation called “AM-BOM-DATA-LTAB” and “AM-BOM-DATA-DTAB”. These tables are also not a big problem to create. But then I want to hook these tables to each other with the “am-bom-update” command in annotation. Then I get the error “You should first retrieve a BOM ...” I get the same error if I want to add bom flags to the drawing. So somewhere there should be a command to say to annotation that he received a BOM somewhere. And now my real question. Is there somebody who customized this bom completely from scratch and can help me with the code? |
#2
|
||||
|
||||
![]() Quote:
Work through this: https://support.ptc.com/help/creo/ce..._cust_bom.html the three functions
================== Adding new / other data you need to register a new BOM Attriubte:
In the example (see link above) this is done e.g. by (defun bomattr-get-partno...) Here it is done with the generic item-attribute functionality, that way the example code is working withtout any database connected. In your case e.g. you can write your own function, and register that one .. Code:
(defun bomattr-get-UWGM-partno (selitem) (or (sd-uwgm-inq-commonname selitem) "n/a") ;; may be shorten the string if its too long ) (docu::docu-register-bom-attr :attr-type "UWGM_PART_NO" :attr-title "WT Part No" :attr-display t :attr-value-fnc #'bomattr-get-UWGM-partno)
Short sequence, usage:
Hint: use Code:
(trace bomattr-get-UWGM-partno) It will be called for each component part of your assembly and should return the windchill's commonname.
__________________
|
#3
|
||||
|
||||
![]()
Additional remark:
I highly recommend to read / work and understand that documention I send the link of. It is well done and working for 25 years. There was no change on this functionality. AFAIR all the standard windchill attributes are already availalble out of the box as text references. So you only have to adapt a BOM Layout and add 'a column'. For your own windchill attribute you can use Code:
(sd-uwgm-inq-model-attribute selitem "CUST_MATERIAL") ; e.g. BTW: my companies Laptop is OFF during the weekend, so I only WROTE but did not test it. For people with less english skills: Entry point DOCU-REGISTER-BOM-ATTR : https://www.bing.com/search?q=%22DOCU-REGISTER-BOM-ATTR%22+site%3Asupport.ptc.com
__________________
Last edited by Wolfgang; 03-05-2023 at 05:58 AM. Reason: adding documentation link as search engine URL |
#4
|
|||
|
|||
Re: BOM issue
Hi Wolfgang,
Thanks for all the information. This was very helpful and it helped me to achieve my goal. thx |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | Search this Thread |
Display Modes | Rate This Thread |
|
|