Skip to content

ExcelWorksheetView.FreezePanes ignoring hidden rows above or columns to the left of freeze point #786

Open
@jtrent614

Description

@jtrent614

When calling ExcelWorksheetView.FreezePanes(int Row, int Column), the Row and Column coordinates ignore hidden rows/columns and instead count only visible rows/cols.

Steps to reproduce:

  • On an empty sheet, hide row 1 and column A
  • Call Worksheet.View.FreezePanes(3, 3)
  • Expected:
    • Pane frozen at cell C3
  • Actual:
    • Pane frozen at cell D4

XML Examples

  • Excel (expected):
    <sheetView tabSelected="1" topLeftCell="B2" workbookViewId="0">
        <pane xSplit="1" ySplit="1" topLeftCell="C3" activePane="bottomRight" state="frozen" />
        <selection activeCell="B2" sqref="B2" />
        <selection pane="topRight" activeCell="C2" sqref="C2" />
        <selection pane="bottomLeft" activeCell="B3" sqref="B3" />
        <selection pane="bottomRight" activeCell="B2" sqref="B2" />
    </sheetView>

image

  • EPPlus (unexpected):
      <sheetView tabSelected="1" topLeftCell="B2" workbookViewId="0">
            <pane xSplit="2" ySplit="2" topLeftCell="D4" activePane="bottomRight" state="frozen" />
            <selection pane="topRight" activeCell="C1" sqref="C1" />
            <selection pane="bottomLeft" activeCell="A3" sqref="A3" />
            <selection pane="bottomRight" activeCell="B2" sqref="B2" />
      </sheetView>

image

Metadata

Metadata

Type

No type

Projects

Status

Pending Release

Relationships

None yet

Development

No branches or pull requests

Issue actions