Bug 68779 - Mixed cell reference is being malformatted
Summary: Mixed cell reference is being malformatted
Status: NEW
Alias: None
Product: POI
Classification: Unclassified
Component: XSSF (show other bugs)
Version: 5.2.3-FINAL
Hardware: PC
: P2 critical (vote)
Target Milestone: ---
Assignee: POI Developers List
Depends on:
Reported: 2024-03-14 09:35 UTC by baha.merzougui
Modified: 2024-03-14 09:35 UTC (History)
0 users


Note You need to log in before you can comment on or make changes to this bug.
Description baha.merzougui 2024-03-14 09:35:59 UTC
When creating a conditional formatting rule using formula String such as:

------------------------------Code snippet------------------------------
SheetConditionalFormatting sheetCF = sheet.getSheetConditionalFormatting();

ConditionalFormattingRule rule = sheetCF.createConditionalFormattingRule(

PatternFormatting fill = rule.createPatternFormatting();
fill.setFillBackgroundColor( IndexedColors.YELLOW.index);
fill.setFillPattern( PatternFormatting.SOLID_FOREGROUND);

ConditionalFormattingRule[] cfRules = new ConditionalFormattingRule[] { rule };

CellRangeAddress[] regions = new CellRangeAddress[] { CellRangeAddress.valueOf( "D1:L10000") };

sheetCF.addConditionalFormatting( regions, cfRules);

The formatting rule from the generated xslx file is written as follow:

The problem seems to be reproducible with every mixed cell referencing; in this example $ref.e$1 , I attempted the other way around $ref.$E1 fixed column changing row same problem.
The fact that the Alpha index of the cell is lower cased is breaking it.