Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • O openpyxl
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 282
    • Issues 282
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 7
    • Merge requests 7
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar

Due to a massive storm of spam, registration on this instance now requires explicit administrator approval. Sorry for the added friction, we're also looking into automatic filtering options.

  • openpyxl
  • openpyxl
  • Issues
  • #1942
Closed
Open
Issue created Jan 19, 2023 by snippet@snippetDeveloper

Print area cannot be parsed if it's a reference to a Table

Excel allows users to create tables and set the print area as whatever the area of that table is. This results in a definedName tag in workbook.xml that openpyxl cannot parse (expects a cell reference)

See attached file, which produces something like

    <definedNames>
        <definedName name="_xlnm.Print_Area" localSheetId="0">InvoiceData[#All]</definedName>
    </definedNames>

This crashes out in the workbook reader as it attempts to extract a cell reference (See here)

The spec (at least according to c-rex) doesn't really provide much guidance on this one. I'm unable to test how LibreOffice handles it.

openpyxl 3.1.0b1

Sample Code

from openpyxl import load_workbook

wb = load_workbook("QueryTable.xlsx")

QueryTable.xlsx

Edited Jan 19, 2023 by snippet
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking