API-Before I go Bonkers about Configs in BOM

Is it possible to get the API to set whether to use the configuration or document name in a BOM? I can't seem to find this in the docs anywhere and recording a macro doesn't offer much more enlightenment.

Reply to
TOP
Loading thread data ...

To further elaborate my question:

What are the API calls to set everything seen in the Configuration Properties Dialog box?

  1. Configuation name (this I can do)
  2. Configuration description (this API seems to be missing)
  3. Configuration comment (this API seems to be missing)
  4. BOM Options for using Document Name, Configuration Name or User Specified Name.
4a. When using a user Specified name how is that set?
  1. Advanced Options suppress feature toggle?
  2. Advanced Options configuration specific color?
  3. Custom Properties (this I know how to do.)
Reply to
TOP

retVal = Configuration.Description (VB Get property)

Comment = Configuration.Comment (VB Get property)

and so on, pretty much everything is under Configuration...

Reply to
Markku Lehtola

I think this covers most of it I am not quite sure of the toggle for the color.

Config.alternateName = "Some Alternate" Config.Description = "This sets description" Config.Comment = "This sets Comment" Config.HideNewComponentModels = True Config.BOMPartNoSource = swBOMPartNumberSource_e.swBOMPartNumber_ConfigurationName Config.SetColor (RGB(0, 255, 0))

Reply to
CS

Sorry to ask such a dumb question. I found them. Thanks.

Reply to
TOP

Thanks. I failed to look in the obvious place: Config.Properties.

Now if I could just change custom properties without invoking the X in the configuration manager tree.

Reply to
TOP

What do you mean? You can change those too.

OldValue = Modeldoc2.customInfo2(config, custominfoname) Modeldoc2.CustomInfo2 (Config, CustomInfoName) = CustomInfoValue

If it is a new field you will need to use

ModelDoc2.AddCustomInfo3 ( Config, CustomInfoName, swCustomInfoType_e.swCustomInfoText, CustomInfoValue)

And to delete

ModelDoc2.DeleteCustomInfo2(Config, CustomInfoName)

To add them to the general document pass an empty string "" as the config.

Reply to
CS

Look at the comments for this example in help: Extract Configuration-Specific Parameters Example (VB)

My goal is to not have the Excel X show up as the icon in the configuration tree after changing a CP. I want to keep the little yellow cube unless I really have a design table.

Reply to
TOP

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.