ATC: ADD WBCODE costcode description |  FROM projectid  LIKE mask

This command adds one or more cost codes to the project identified by the current target document. No save is required. If the cost code already exists the script continues; description is not updated. This command is not supported for background scripts.

  • costcode is optional, but if used must be followed by description. The cost code must not include spaces or mask separators.
  • description is optional, but if used by must preceded by costcode. The freeform description can be any text and can include spaces.
  • FROM projectid is optional alternative to costcode and description.  The FROM clause will copy both cost codes and their descriptions. The projectid can include bookmarks or a variable reference.
  • ENUM alias.field is an optional alternative to costcode.  The unique list of values in alias.field are enumerated and the cost codes are added with their default descriptions.
  • LIKE mask is an optional modifier for the FROM clause to filter cost codes.  For example, LIKE 16* will add only cost codes that begin with 16.  The default mask is * for all cost codes.

Examples:

ATC: ADD WBCODE 16500 Electrical Materials

The above example means “add the cost code ‘16500’ with a description of ‘Electrical Materials’ to the project.”

ATC: ADD WBCODE FROM GC999 LIKE 15*

The above example means “load the WBS from project GC999 and copy only the cost codes that begin with 15.”

ATC: ADD WBCODE ENUM DocItem.SourceItemNumber 

The above example means “load the unique values of SourceItemNumber from all item rows and add those cost codes ”


Last updated: September 3, 2026 at 7:22 am;  green text = new

Related Post

ATC: CLOSEATC: CLOSE

ATC: CLOSE This command sets the closed date on the current document to today. This effectively closes the document, regardless of status. Example ATC: CLOSE The above example means “close