On 16 Jan 2025, at 9:02, Eugenijus Januškevičius wrote:
The boundaries do not intersect, but just the highest level is grouped in
the XLSX file. Do I miss something? There is moving block and the length of
the first and the second grouping is not known in advance. I could collect
row ranges and crealte lelev 2 grouping after L1, if it would help.
I hate everything to do with outlining/grouping in OOXML: the two are needlessly conflated and also implemented differently for rows and columns and the documentation is not very helpful.
Really, the best thing to do is to create a sample worksheet in Excel, open the source XML in a suitable editor and then work out what you need to do in Openpyxl. From memory, because I was trying something similar last year, there are problems with adjacent groups of rows.
Charlie
--
Charlie Clark
Managing Director
Clark Consulting & Research
German Office
Sengelsweg 34
Düsseldorf
D- 40489
Tel: +49-203-3925-0390
Mobile: +49-178-782-6226