Word(.doc/.docx) Report In Odoo
By Muhamed Yasir,

  Category: Odoo     Comments: 2

As we know already, Odoo is providing most of the reports in PDF only. In some cases, we have option to export the report in Odoo. But most of the cases, we may face a situation to get the report in word file(.docx / .doc). This in need when we need to modify the content of the file like some application forms, certificate templates etc. Word Report In Odoo support us to get the reports in .doc or .dox format.

To manage this, by using python-docx library, we can print application forms, certificates templates and other word reports in Odoo. python-docx is a Python library for creating and updating Microsoft Word (.docx) files.

Installation

python-docx is hosted on PyPI, so installation is relatively simple, and just depends on what installation utilities you have installed.

It is possible to install python-docx  with pip if you have it available:

Installation of python-docx with pip for generating Word Report In Odoo

python-docx can also install using easy_install, although this is discouraged:

Installation of python-docx using easy_instal

 

If neither pip nor easy_install is available, it can install manually by downloading the distribution from PyPI, unpacking the tarball, and running setup.py:

python-docx installed manually by downloading the distribution from PyPI, unpacking the tarball, and running setup.py

python-docx depends on the lxml package. Both pip and easy_install will take care of satisfying those dependencies for you, but if you use this last method you will need to install those yourself.

Opening a document  

 Opening a document  

Adding a paragraph

Adding a paragraph to word report in Odoo

Adding a heading

Adding a heading for word report in Odoo

Addition of page break

Adding a page break for word report in Odoo

Insert a table

Adding a table for word report in Odoo

Adding a picture

Adding a picture for word report in Odoo

Applying a paragraph style

Applying a paragraph style for word report in Odoo

Using bold and italic

Applying bold and italic for word report in Odoo

Applying a character style

Applying character style for word report in Odoo

Example of python-docx :

Example of python-docx

This will help you to do Odoo custom Xls reports as per your requirements. So this is one of the most common request from Odoo users. This Odoo Customization by the software company Technaureus Info solutions helps to meet the users demand.

2
Leave a Reply

avatar
2 Comment threads
0 Thread replies
0 Followers
 
Most reacted comment
Hottest comment thread
1 Comment authors
Elmer Recent comment authors
  Subscribe  
newest oldest most voted
Notify of
Elmer
Guest
Elmer

Now, how we download?

trackback

[…] In other case as we know already, Odoo is providing most of the reports in PDF only. In some cases, we have option to export the report in Odoo. But most of the cases, we may face a situation to get the report in word file(.docx / .doc). This is required when we need to modify the content of the file like some application forms, certificate templates etc. Word Report In Odoo support us to get the reports in .doc or .dox format. Technaureus also providing Word(.doc/.docx) Report In Odoo. […]

shares