Odoo Help


Can OpenERP print UPC barcodes on product labels? [Closed]

Ray Carnes
on 8/2/13, 9:26 PM 3,622 views

The Question has been closed

Ray Carnes
on 08/02/2013 21:33:40

I've seen videos and have looked at some community modules but nothing I've tried works.

How are people getting this working?


Ray Carnes

--Ray Carnes--
| 9 7 9
Keyport, United States
--Ray Carnes--

Senior ERP Analyst

OpenERP 6.1, 7.0; Odoo 8.0, 9.0, 10.0 and 11.0.

Completed Odoo Functional and Technical Training.

Functional Areas:

  • CRM/Sales

  • Inventory

  • Manufacturing

  • Accounting

  • Purchasing

Major Skills:

  • Business Process Reengineering

  • Efficiency Consulting

  • User Needs and GAP Analysis;

  • Functional and Technical Design;

  • Prototyping and Proof of Concepts;

  • Requirements Specifications;

  • Agile Implementation;

  • Data Migration;

  • Configuration & Customization (UI and code);

  • Integration - Odoo and non Odoo Applications and Services;

  • Training and Knowledge Transfer;

  • Go Live Support;

  • Helpdesk;

  • Version Upgrades and Migration.

  • Accounting Expert.

I have over 20 years of experience empowering and enabling users with enterprise information systems that make a real and measurable difference in their ability to proactively manage their businesses and organizations. 

I am a skilled Communicator and I only take the serious things seriously!

Ray Carnes
On 8/2/13, 9:28 PM


UPC is now supported in ReportLab 2.7.

1) Remove the 'old' version of ReportLab:

sudo apt-get purge python-reportlab

2) If you don't have easy_install available, then install it:

sudo apt-get install python-setuptools

3) Install the 'new' version of ReportLab

sudo easy_install reportlab

4) Add support to OpenERP for UPC by adding an entry to the end of the codes dictionary in server/openerp/report/render/rml2pdf/trml2pdf.py:

'upc': lambda x:  createBarcodeDrawing('UPCA', value=x, **args),

5) Add the default_code (or the field you use for UPC) to addons/product/report/product_label.xml:

 <default_code type="field" name="default_code"/>

6) Make changes to addons/product/report/product_label.xsl to use the new tag and the default_code field:

 <barCode code='upc' height="35.0" width="55.0">
     <xsl:value-of select="default_code"/>


image description

UPDATE: I was premature about posting this. As you can see from the screenshot, the UPC code isn't formatted correctly. I will update the post when this is resolved. OpenERP is helping us do this.

Ray Carnes
on 8/9/13, 5:18 PM

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

0 follower(s)


Asked: 8/2/13, 9:26 PM
Seen: 3622 times
Last updated: 3/16/15, 8:10 AM