Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:

  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. Be respectful, on topic and if you see a problem, Flag it.

If you would like to contact our Community Manager personally, feel free to send a private message or an email.

BOM ability to add part configuration property column?

mj_powersmj_powers Member Posts: 9 PRO
edited September 2018 in Data management
Just wondering if there is a way to add a specific part configuration property as a column item within the native Onshape BOM.

For example I have an assembly with several 2x4 lumber posts - each of different length.
Within the BOM they show as separate parts with the same exact name since they are from the same configuration part.
I must manually add the configuration properties built into the part in the "description" column  - in this example the length of the 2x4 post.



  • Don_Van_ZileDon_Van_Zile Member Posts: 195 PRO

    In the Configured Part Studio, you can add Configuration Specific Properties as shown:

  • MBartlett21MBartlett21 Member Posts: 1,572 EDU
    Or you can set the description with a custom feature
    MB - I make FeatureScripts: view FS (My FS's have "Official" beside them)
  • lorenz_michelslorenz_michels Member Posts: 3 EDU
    I still don't get it. I have a part with different configurations and one configuration variable...

    and with the part properties there are some standard properties...

    in the bom i can't select my configuration variable "length" which is defined in the part studio but is determined in the assembly

    how to get the lengths in the bom?
  • john_mcclaryjohn_mcclary Member, Developers Posts: 1,904 PRO
    edited March 10
    The BOM only shows Properties only.

    you will need to add a "Custom Property" to your company (PRO / Enterprise account required)

    otherwise you can use an easy featurescript to add your length to the name or description property.
    Keep in mind, once you manually edit any property, you can no longer use a featurescript to set it's value

    FeatureScript 1024; import(path : "onshape/std/geometry.fs", version : "1024.0"); annotation { "Feature Type Name" : "Add Length To Name" } export const NameLength = defineFeature(function(context is Context, id is Id, definition is map) precondition { annotation { "Name" : "Name" } definition.Name is string; annotation { "Name" : "My Length" } isLength(definition.myLength, LENGTH_BOUNDS); annotation { "Name" : "Part", "Filter" : EntityType.BODY && BodyType.SOLID && AllowFlattenedGeometry.YES, "MaxNumberOfPicks" : 1 } definition.entities is Query; } { const parts = evaluateQuery(context, definition.entities); var Name = definition.Name ~ " " ~ toString(roundToPrecision((definition.myLength / inch),2)) ~ " LG" ; if (parts == []) throw regenError(ErrorStringEnum.CANNOT_RESOLVE_ENTITIES, ["entities"]); setProperty(context, { "entities" : parts[0], "propertyType" : PropertyType.NAME, "value" : Name }); setProperty(context, { "entities" : parts[0], "propertyType" : PropertyType.DESCRIPTION, "value" : Name }); });

  • NikolaiNNikolaiN Member Posts: 6
    @lorenz_michels imho, there is no need for using custom props in your case. Suppose using configured part properties for "Name" and for "PartNumber" in part studio (as suggested by @Don_Van_Zile) is enough. Having that, you will see the proper values of those properties in BOM. Just checked - it works.

  • Alexei_PittowiczAlexei_Pittowicz Member Posts: 37 PRO
    @lorenz_michels I use this workflow too and it works well if you have a pre-defined list of configurations. Not quite as useful if you are generating the configs "on the fly" in the assembly via a config variable. This is trickier and needs funky feature scripts (as I guess is outlined above)

    I often set up a "custom" part studio (defined with "continuous" config variables) and then a second "stock" part studio with the "custom" part derived into it. This "Stock" studio is then configured with a finite list and with configured part names. 

     Wish I could use configurable assembly "part names" in the same way, but appears not for now.  Onshape, please can you make it so?? :)
  • owen_sparksowen_sparks Member, Developers Posts: 2,281 PRO
    I think there will plenty of good things to come in armpits configurations. Oh FFS android, "assembly configurations", not 'armpit configurations".
    Production Engineer
    HWM-Water Ltd
  • 3dcad3dcad Member, OS Professional, Mentor Posts: 2,380 PRO
    I'm not much of a FS coder but it only took me one night with couple of emails to support along with examples in forum to put this together and I'm really happy I gave it a shot. A real time saver until we get similar built-in functionality.

    It's only one feature in ps tree to get all parts dimension into bom.
  • Florian_SchneiderFlorian_Schneider Member Posts: 6 PRO
    edited June 5
    Hi There

    My question would be, how did you rename the property?

    I would like to add my own Properties to my BOM, something like "Price" or "Comment". I dont like "Title1" "Title2" and so on... 

    How can i change the titles of the properties? (i mean your columns are named X, Y and Z) How did you do that?

  • john_mcclaryjohn_mcclary Member, Developers Posts: 1,904 PRO
    Goto your company's settings and select properties

  • owen_sparksowen_sparks Member, Developers Posts: 2,281 PRO
    edited June 5
    As a pro user you have access to "custom properties".

    Here are some of mine as an example:-

    I'd imagine @3dcad has made himself some custom properties, and then used a featurescript to populate them.  A custom property, whether populated by the user or via FS can then be used in the BOM just like any other native property.

    Owen S.
    Production Engineer
    HWM-Water Ltd
  • 3dcad3dcad Member, OS Professional, Mentor Posts: 2,380 PRO
    Haven't notice this until now, that's exactly what I did: created custom properties x, y and z and then use fs to populate them with a single feature.
Sign In or Register to comment.