Skip to main content
MSME Sales BoosterAcademy

Item code templates: generate item codes automatically

AdministrationUpdated 25 Nov 2026

Example. A steel trader wants every plate item coded like PL-MS-10MM-0001. The administrator opens Admin → Application Settings → Item Coding, clicks Create Code Template, names it Plates, chooses Applies To Product Group and Material, and picks the product group PL-PLATES and the material MS-Mild Steel. The segments are: Product Group PG.CODE, Separator -, Material MAT.CODE, Separator -, Dimension THICKNESS, Separator -, Counter 4. Item Code Preview shows the shape of the code. Later, a buyer creates an item in that product group and material, enters a thickness of 10, and clicks Auto-Generate Item Code: the Item Code box fills with PL-MS-10MM-0001.

What it does and when to use it#

An item code template describes how item codes are built, piece by piece. When someone creates an item whose product group, material or customer fits a template, the item master offers Auto-Generate Item Code and fills in the code for them. Use templates when you want codes in a consistent format, with a running number per family of items, instead of typing codes by hand.

Templates never change codes of items that already exist. Typing a code by hand is always still possible.

Before you start#

✅ Before you start

0/4 ready

Open the templates#

Go to Admin → Application Settings → Item Coding. The Admin page also has an Item Coding card under Data & Masters. The page Item Coding & Templates lists your templates. Without App Settings read permission you see a no-permission page instead.

Item code templates don't depend on the Company's Application Settings. Even when the Company's settings haven't been set up yet (no message is shown for this when you sign in or switch Company), you can still open Item Coding and use its templates; contact MSME Sales Booster support about the Company's other settings.

The list#

ColumnWhat it shows
Template NameThe template's name
Item Code FormatThe segments joined together, with the counter shown as 0001 (for 4 digits)
Applies ToProduct Group, Material and/or Customer
PriorityThe template's priority, used when two templates fit equally well
Created ByWho created it
StatusACTIVE or CANCELLED

Filter by Created By or Status (Active, Cancelled). Each row has View and Edit. Edit is greyed out only for a cancelled template and for templates created by someone else (Only the creator or designated users can update this entry). It is not greyed out for a missing permission: without Admin → App Settings → Update, saving the change is refused instead (see Edit a template).

The list shows the templates of every Company in your workspace. The item master, however, only offers templates that belong to the Company you're working in (see How a template is chosen).

Create a template#

  1. Start a template

    📍 Item Coding & Templates → Create Code Template

    Create Code Template is greyed out without App Settings Create permission. The page Create Item Code Template opens.

  2. Fill in the template details

    📍 Template Details

    Enter Template Name*, an optional Priority (1 to 100) and Applies To* (one or more of Product Group, Material, Customer). For each choice, a box appears: Product Group*, Select Material* or Customer*. Add a Description if you like.

  3. Add the segments

    📍 Item Code Template table

    Click + Add Segment. For each row choose Select Type and then Select Value/Token. Add inserts a row below; Remove deletes a row. Keep the rows in the order the code should read.

  4. Check the preview and create

    📍 Item Code Preview → Create

    Item Code Preview shows the segments joined together. Click Create. The template is saved as ACTIVE.

Template fields#

FieldWhat it does
Template Name*Must be unique among the Company's active templates (the name of a cancelled template can be used again). A name already used shows Template name already exists. under the field, and Create stays greyed out
Priority1 to 100. When two templates fit an item equally well, the higher priority wins
Applies To*Which item details the template is tied to: Product Group, Material, Customer. Removing a choice clears the segments that depend on it, and removing Customer clears the chosen customer
Product Group*The product group the template is for (shown as code-name)
Select Material*The material the template is for (shown as code-name)
Customer*The customer the template is for. It must be a customer of the Company you're working in
DescriptionFree text for your own reference

Segment types#

Select TypeSelect Value/TokenWhat goes into the code
ItemITEM.NAMEThe item's Name
Product GroupPG.CODE or PG.NAMEThe product group's code or name
Dimension (only with Applies To Product Group)A dimension of the chosen product group, for example THICKNESSThe value entered for that dimension on the item, followed by its default unit from the product group, for example 10MM
MaterialMAT.CODE or MAT.NAMEThe material's code or name
Customer (only with Applies To Customer)CUST.CODE, CUST.PART_NO or CUST.REV_NOThe customer's code, or the customer part number or revision number entered on the item
Maturity (only with the Spirit maturation module)MATURITY.DURATION or MATURITY.UNITThe item's maturity duration or unit
CustomAny text you typeThat text, unchanged
CounterNumber of digits (1 to 50; 4 when you pick Counter)A running number padded with zeros, for example 0001
Separator-, /, X, _, ( or )That character

How a template is chosen#

On Item Master → Create, as soon as a Product Group, Select Material or customer is chosen, MSME Sales Booster looks for a template:

  1. Only ACTIVE templates of the Company you're working in are considered.
  2. A template fits only if every detail it is tied to matches the item. A template tied only to a product group fits every item of that group, whatever its material or customer. A template tied to a material doesn't fit an item without that material.
  3. If several fit, the one matching the most important details wins: a product group match counts most, then material, then customer.
  4. Still a tie: the higher Priority wins, then the most recently created template.

When a template is found, the item form shows a note Match this item code template format to generate valid item code: with the format, and an Auto-Generate Item Code link under Item Code*.

Generate a code on the item master#

  1. Fill in the item details first

    📍 Item Master → Create → Item Code Configuration

    Choose the Product Group, Select Material and customer, and enter the Name, dimension values and customer part details the template uses. Segments whose value is empty add nothing to the code.

  2. Generate the code

    📍 Item Code* → Auto-Generate Item Code

    Click Auto-Generate Item Code. The Item Code* box fills in. You can still edit it before saving.

  3. Save the item

    📍 Item Master → Create

    Saving the item uses up the counter number for that template.

How the counter works#

  • Each template has its own counter, shared by all items created from it.
  • The next number is one more than the highest number used by an active item created from this template. It isn't reserved until the item is saved: if two people generate a code at the same time, they see the same number, and the second save is refused because item codes must be unique.
  • If the item with the highest number is cancelled or deactivated, its number can be given again.
  • A hyphen (-) or slash (/) at the very start or end of the generated code is dropped. Other separators (X, _, brackets) are kept.

See Customers, vendors and items for the rest of the item form.

Edit a template#

In the list, open Edit on the row (Edit is greyed out for anyone but the person who created the template, and for cancelled templates). The page has the same fields as when creating; the customer box is labelled Company Name* here. Change the fields and click Update. Your role needs Admin → App Settings → Update: without it, Update shows an Error message You do not have permission to perform this action. and nothing is changed.

Changes apply to codes generated afterwards. Items that already exist keep their codes, and the counter continues from the highest number used.

Open Edit from the list: going straight to the edit page's web address shows an empty form.

View and cancel a template#

View opens View Item Code Template with two tabs:

  • Details: Template Details (Template Name, Description, Created By, Status, and Cancellation Reason once cancelled), Applies To (customer, product group or material) and Segments (Sr, Type, Value / Token).
  • Audit Log: who created and changed the template, and when.

To stop using a template, click Cancel on the view page. The dialog explains Once cancelled, this template cannot be modified. Create a new template if needed. Enter the Reason For Cancellation* and click Proceed. The template shows CANCELLED and is no longer offered on the item master. Items already coded with it keep their codes. Cancel is greyed out for a cancelled template and for a template created by someone else. Your role also needs the Cancel tick on Admin → App Settings: without it, Proceed shows an Error message You do not have permission to perform this action. and the template stays ACTIVE.

ACTIVE
Offered on the item master when it fits the item.Next: Cancel
CANCELLED
Kept for reference; never offered and can't be edited.Next: None: create a new template

Common problems#

Next step · PurchaseCreate items in the item master →