Skip to Content
Odoo Menu
  • Sign in
  • Try it free
  • Apps
    Finance
    • Accounting
    • Invoicing
    • Expenses
    • Spreadsheet (BI)
    • Documents
    • Sign
    Sales
    • CRM
    • Sales
    • POS Shop
    • POS Restaurant
    • Subscriptions
    • Rental
    Websites
    • Website Builder
    • eCommerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Supply Chain
    • Inventory
    • Manufacturing
    • PLM
    • Purchase
    • Maintenance
    • Quality
    Human Resources
    • Employees
    • Recruitment
    • Time Off
    • Appraisals
    • Referrals
    • Fleet
    Marketing
    • Social Marketing
    • Email Marketing
    • SMS Marketing
    • Events
    • Marketing Automation
    • Surveys
    Services
    • Project
    • Timesheets
    • Field Service
    • Helpdesk
    • Planning
    • Appointments
    Productivity
    • Discuss
    • Approvals
    • IoT
    • VoIP
    • Knowledge
    • WhatsApp
    Third party apps Odoo Studio Odoo Cloud Platform
  • Industries
    Retail
    • Book Store
    • Clothing Store
    • Furniture Store
    • Grocery Store
    • Hardware Store
    • Toy Store
    Food & Hospitality
    • Bar and Pub
    • Restaurant
    • Fast Food
    • Guest House
    • Beverage Distributor
    • Hotel
    Real Estate
    • Real Estate Agency
    • Architecture Firm
    • Construction
    • Estate Management
    • Gardening
    • Property Owner Association
    Consulting
    • Accounting Firm
    • Odoo Partner
    • Marketing Agency
    • Law firm
    • Talent Acquisition
    • Audit & Certification
    Manufacturing
    • Textile
    • Metal
    • Furnitures
    • Food
    • Brewery
    • Corporate Gifts
    Health & Fitness
    • Sports Club
    • Eyewear Store
    • Fitness Center
    • Wellness Practitioners
    • Pharmacy
    • Hair Salon
    Trades
    • Handyman
    • IT Hardware & Support
    • Solar Energy Systems
    • Shoe Maker
    • Cleaning Services
    • HVAC Services
    Others
    • Nonprofit Organization
    • Environmental Agency
    • Billboard Rental
    • Photography
    • Bike Leasing
    • Software Reseller
    Browse all Industries
  • Community
    Learn
    • Tutorials
    • Documentation
    • Certifications
    • Training
    • Blog
    • Podcast
    Empower Education
    • Education Program
    • Scale Up! Business Game
    • Visit Odoo
    Get the Software
    • Download
    • Compare Editions
    • Releases
    Collaborate
    • Github
    • Forum
    • Events
    • Translations
    • Become a Partner
    • Services for Partners
    • Register your Accounting Firm
    Get Services
    • Find a Partner
    • Find an Accountant
    • Meet an advisor
    • Implementation Services
    • Customer References
    • Support
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Get a demo
  • Pricing
  • Help

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Accounting
  • Inventory
  • PoS
  • Project
  • MRP
All apps
You need to be registered to interact with the community.
All Posts People Badges
Tags (View all)
odoo accounting v14 pos v15
About this forum
You need to be registered to interact with the community.
All Posts People Badges
Tags (View all)
odoo accounting v14 pos v15
About this forum
Help

Can Frame boundaries be changed in SXW-RML reports?

Subscribe

Get notified when there's activity on this post

This question has been flagged
rmlreportsxwlandscapeboundary
2 Replies
9966 Views
Avatar
Aitzol

I am trying to create a new SXW RML report in landscape format. I have been able to convert the RML to A4 landscape mode but I have some issues with a tables and page breaks.

I'd like the report to display 4 tables, all of them in one page. This is the draft of the report I am designing:

Image: www.solid-rock-it.com/web-solid-rock/blog/images/OpenERP/Captura.PNG

I would like the Table3 and Table4 to be rendered lower than in the draft. But the problem is that if I add a new line before the Table3 or Table4, the RML conversion creates a new page break, and the tables are rendered in a second page.

I think the problem has something to do with the frame size and its boundaries. As it can be seen in the previous image in which the boundaries are displayed, the bondaries are configured as if the page was in portrait mode instead of landscape. How can I change the boundaries to adapt them to landscape mode?

RML file:

<?xml version="1.0"?>
<document filename="test.pdf">
  <template pageSize="(842.0,595.0)" title="Test" author="Martin Simon" showBoundary="1" allowSplitting="20">
    <pageTemplate id="first">
      <frame id="first" x1="57.0" y1="57.0" width="728" height="481"/>
    </pageTemplate>
  </template>

Thanks,

0
Avatar
Discard
Keyur

Hi Aitzol, can you please tell me which OpenERP version you are using? Make sure you are upto latest updates. Thanks

Aitzol
Author

I am using openerp 6.1.1. Fortunately, I have been able to find a solution to the problem

Avatar
Keyur
Best Answer

Hi Aitzol, tables are not displayed properly because the report is A4 size in portrait. You just need to convert portrait document in landscape mode then it will be in proper order. First open your sxw file in there go to Format->Page menu there you can see Orientation:Landscape.

image description

You can also set page size from rml. Generally template pagesize is (842,595) for landscape report. You can also change in frame tag as per your need.

  <template pageSize="(842.0,595.0)" title="Test" author="Martin Simon" allowSplitting="20">
    <pageTemplate id="first">
      <frame id="first" x1="35.0" y1="35.0" width="772" height="525"/>
       <header>
                //Your Company header
      </header>      
    </pageTemplate>
  </template>
1
Avatar
Discard
Aitzol
Author

Thanks Keyur, The SXW report is already in landscape mode and the page layout in the PDF is a A4 in landscape format, as my previous image shows (notice the right margin). The problem is that the page boundaries remain as if it was in portrait mode.

Aitzol
Author

The strangest thing is that the template's and frame's sizes are already configured for landscape mode. The boundaries however, remain to be in portrait mode. This is the RML:

<?xml version="1.0"?> <document filename="test.pdf"> <template pageSize="(842.0,595.0)" title="Test" author="Martin Simon" showBoundary="1" allowSplitting="20"> <pageTemplate id="first"> <frame id="first" x1="57.0" y1="57.0" width="728" height="481"/> </pageTemplate> </template>

Image of the PDF, still with wrong boundaries: http://www.solid-rock-it.com/web-solid-rock/blog/images/OpenERP/Captura2.PNG

Keyur

Maybe because you are printing barcode report so that's why the report is not in actual width try to reduce the width of the barcode table then it might help. Thanks

Avatar
Aitzol
Author Best Answer

I finally found the solution to the problem with the page landscape layout. The problem was that although the page was in landscape mode, the page frame remained in portrait mode.

I found that all dimensions in the rml were ok and the problem was somewhere else, in the report's python file to be precise:

report_sxw.report_sxw('report.modulename.product.label','mrp.production','addons/modulename/report/product_label.rml',parser=order,header=False)

The problem has been solved by adding "header=False" parameter to the report_sxw method call. It seems that by not adding this parameter, OpenERP modifies the page layout in order to add the header, which is configured to be in portrait mode. This was overwriting the settings for landscape mode in my RML file.

0
Avatar
Discard
Luis Lozano

I have the same problem, I have OpenERP Online, do you know where can I find this file? Thanks

Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Sign up
Related Posts Replies Views Activity
can we change rml file to sxw ?
rml report sxw
Avatar
Avatar
Avatar
2
Mar 15
7186
How to repeate column in RML report
rml report sxw
Avatar
0
Mar 15
6381
odt format report in rml reporting
rml report sxw odt
Avatar
Avatar
1
Mar 15
5428
list index out of rangeparagraph text u'<para></font></para>' caused exception" Solved
rml openoffice report sxw openerp7
Avatar
Avatar
Avatar
4
Aug 15
7193
.sxw to .rml convertion problems can anybody help?
rml reporting report sxw convetrion
Avatar
Avatar
Avatar
2
Mar 15
6470
Community
  • Tutorials
  • Documentation
  • Forum
Open Source
  • Download
  • Github
  • Runbot
  • Translations
Services
  • Odoo.sh Hosting
  • Support
  • Upgrade
  • Custom Developments
  • Education
  • Find an Accountant
  • Find a Partner
  • Become a Partner
About us
  • Our company
  • Brand Assets
  • Contact us
  • Jobs
  • Events
  • Podcast
  • Blog
  • Customers
  • Legal • Privacy
  • Security
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo is a suite of open source business apps that cover all your company needs: CRM, eCommerce, accounting, inventory, point of sale, project management, etc.

Odoo's unique value proposition is to be at the same time very easy to use and fully integrated.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now