web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Answered

Barcode not showing properly in a label template.

(7) ShareShare
ReportReport
Posted on by
Dear,
 
I made a label template for the labels we print at Posted warehouse receipt. I currently have the problem that the barcode in the top left (See picture) is not showing properly. It has a gap in it. Does anyone know how to fix this?
 
Kind regards,
 
Joey
  • Suggested answer
    Keval Lathiya Profile Picture
    on at
    Barcode not showing properly in a label template.
    Hello,
     

    Please note that Business Central only provides basic barcode functionality using the EAN (GTIN) field. If you require a more detailed or customized barcode print, this is not available out-of-the-box.

    To implement a fully customized barcode solution, coordination with a technical consultant is necessary. A tailored development would be required to meet your specific requirements.

    Thank you for your understanding.

  • Suggested answer
    Sohail Ahmed Profile Picture
    on at
    Barcode not showing properly in a label template.

    Hi Joey,

     

    That usually happens if the wrong barcode font/size is used or if the printer DPI doesn’t match. Double-check the font (e.g. Code128/Code39), make sure the field isn’t resizing, and test with a scanner sometimes it looks broken but still scans fine.

     

    Can you share which layout you’re using (RDLC, Word, or a label tool like Zebra/Bartender)? That will help narrow it down.

     

    ✅ Mark this as the verified answer if helpful.

  • Joey Portier Profile Picture
    on at
    Barcode not showing properly in a label template.
    Hi Sohail,
     
    As extra information. We use a word (XML) template for the label. This is being printed by a Zebra printer (The printer itself is working fine). The current fond we are using for that is IDAutomationC39S.
     
    The code that we need to print has ## in it. These are mandatory as they are part of the code that needs to be scanned.
     
    I attached a picture of the word template.
  • Suggested answer
    Alex A Profile Picture
    on at
    Barcode not showing properly in a label template.
    The problem is likely the hash marks ##. Certain characters like the hash marks can behave unpredictably in NAV/BC in various places (;@%#'). The hash marks could be being rendered as a control or delimiter character (or other behaviors) or if the barcode generator/printer doesn't support them.
     
    Options:
     - Replace the ## with a safe character temporarily to test if the barcode renders correctly.
       - Remove the hash marks from the code or test this with another code that does not have hash marks and see if the label comes out correctly. Then you will know.
     
     - Try switching to a more robust barcode type with proper encoding support.
     
     - There might be a way to "escape" the ## with ASCII characters. This means replacing the hash marks with an ascii character that might render correctly:
       - # (in HTML contexts)
       - Hex: \x23 or %23 depending on the language or barcode tool
       * If you're using a NAV report with embedded barcode logic, escaping might not work unless the barcode library explicitly supports it.
         - If you're using a barcode font (like Code 39), escaping won't help—you need to ensure the font itself supports #.
         - If you're using a barcode image generator or DLL, check its documentation for character encoding rules.
     
  • Suggested answer
    Khushbu Rajvi. Profile Picture
    on at
  • Verified answer
    Jeffrey Bulanadi Profile Picture
    on at
    Barcode not showing properly in a label template.

    Hi Joey,

    Barcode gaps can undermine scan reliability and cause real friction in warehouse operations. From the image you shared, it looks like the issue stems from how special characters are rendered in the barcode string, especially the ## and * markers around the lot number.

    Here’s what I’d recommend checking:

    • If you're using Code39, remember it only supports uppercase letters, digits, and a limited set of symbols. Characters like # and * can behave unpredictably depending on the font or rendering engine.
    • The * symbol is often used as a start/stop delimiter in Code39. If you include it manually (e.g., *LOT25000106*), make sure your barcode font isn’t duplicating it internally. Otherwise, you’ll get visual gaps or unreadable output.
    • Try removing the manual * and let the barcode font handle the framing. So instead of *LOT25000106*, just use LOT25000106 and see if the gap disappears.
    • If the ## is mandatory for your logic, consider switching to Code128, which handles a broader character set and is less prone to spacing issues.
    • Also check the font size and spacing in your label template. Word-based templates can sometimes stretch or compress barcode fonts, especially if the field is auto-sized or wrapped.


    Once you’ve adjusted the string and confirmed the font behavior, test the printed label with a scanner to ensure it reads cleanly and matches the expected value.

    Helpful References
    IDAutomation Barcode Fonts Official Site
    Barcode Printing in Business Central Yzhums

    Code128 vs Code39 BarcodeFAQ


    If you find this helpful, feel free to mark this as the suggested or verified answer.

    Cheers
    Jeffrey

  • Suggested answer
    Sumit Singh Profile Picture
    on at
    Barcode not showing properly in a label template.
    Hi Joey, 
     
    The most likely solution is to adjust the properties of the barcode field in your report layout file (RDLC or Word).
    1. Increase Textbox Width: Open your custom report layout. Select the textbox that contains the barcode and slightly increase its width. This usually provides enough space for the barcode to render completely.
    2. Check the CanGrow Property (for RDLC): If you are using an RDLC layout, select the barcode's textbox. In the Properties window, ensure the CanGrow property is set to True. This allows the textbox to expand vertically if needed, which can sometimes help with rendering.
    3. Verify Barcode Symbology: Ensure you are using a suitable barcode font/symbology (like Code 128) that can handle your data string (C-000008##LOT25000106). The special characters (##) might be problematic for simpler symbologies like Code 39.
    Official references:- 
    Note: This answer is based on my understanding, with Microsoft Copilot helping me organize and polish the wording.
    Mark the Boolean true “Does this answer your Question” if this was Helpful.
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Pallavi Phade – Community Spotlight

We are honored to recognize Pallavi Phade as our Community Spotlight honoree for…

Leaderboard > Small and medium business | Business Central, NAV, RMS

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans