Hi @NikelARH4K2. This type of situation can be complicated to fully understand and deal with. I pretty much never use 'frame' or 'pipe' stuff, so I am not 100% sure if those files will be treated as ReadOnly from Inventor's perspective or not.
If they are not treated as ReadOnly, then we may be able to create a secondary parameter with a common name (same name in frames & pipes) in each of those files, who's value is set to the name of that other parameter (G_L or PL), so that we could use that common parameter to drive the 'Base Quantity' for all those types of parts, then set that parameter to exported, then set the formatting of the custom iProperty that exporting the parameter creates. Then include that custom iProperty as a column in your PartsLists.
Understanding what all those quantity related terms mean can also be confusing. The following is just a quickie explanation of those terms, and how they are controlled on the document side.
BOMQuantity (an Inventor API object used to access those types of settings, in multiple places)
- Base Quantity: (in Document Settings, per model document)
- This will either be set to 'Each' (by default), or set to reference a specific Parameter.
- If set to reference a Parameter, then the numerical value of that Parameter is used as part of the quantity calculations.
- The 'Units' of this Parameter must be a type of linear distance, mass, or volume.
- Base Units: (in Document Settings per model document)
- Will be 'Each' by default, but if Base Quantity is set to a Parameter, then this will usually get set to the same units as that Parameter.
- However, when Base Quantity is set to a Parameter, this can be set to different Units than that Parameter, as long as it conforms to the distance, mass, or volume type units.
- Unit Quantity: (in Document Settings per model document)
- This is the calculated result of Base Quantity and the Base Units.
- This will usually have the same value as Base Quantity, if the Base Units is set to the same units as the Base Quantity parameter's units.
- However, if the Base Units is set to different units then the Base Quantity parameter's units, then this value can be different than the Base Quantity.
- Item Quantity: (assembly BOM & PartsList only)
- This is always an Integer, representing the 'net' quantity of occurrences of this item are present in the assembly.
- By 'net', I mean it will not include occurrences who's BOMStructure is set to phantom or reference.
- Total Quantity: (assembly BOM only)
- This is the product (calculated result) of multiplying model document settings based Unit Quantity and the assembly level Item Quantity together.
In a drawing, the PartsList is referencing a DrawingBOM, then that DrawingBOM is referencing an assembly's BOM. But the assembly's BOM can not be navigated like a table, like we can with a drawing's PartsList, and we can easily override cell values in a PartsList, and can easily tell if values in a PartsListCell are 'static' or not. So, what you want to do may be possible, but the code may require product/designer specific knowledge built into it to recognize what each row of the PartsList represents, and how they should be handled for the automation code to work properly. We can dig down from the PartsListRow to the DrawingBOMRow, then on to the BOMRow, but it is a little more complicated than it seems like it should be.
As far as keeping the PartsList data updated, since some data may need to be static, there is not really any good event listed in the iLogic 'Event Triggers' for that purpose. The updates may need to be driven from the assembly document side, using one or more custom event handler blocks of code that may be more specific to when BOM related details change.
Wesley Crihfield

(Not an Autodesk Employee)