xlsx freeze rows problem
-
Hello, when I create a dynamic sheet in the xlsx template, I want to freeze the first 2 rows of the shhet. I want to apply it in the example I left below. How can I do this?
thank you.
-
This is what you find in the
xl/worksheets/sheet1.xml
when saving excel with freezed rows<sheetViews> <sheetView tabSelected="1" workbookViewId="0"> <pane ySplit="1" topLeftCell="A2" activePane="bottomLeft" state="frozen"/> </sheetView> </sheetViews>
This can be dynamically added using
xlsxAdd
xlsx transformation helper like this{{#xlsxAdd "xl/worksheets/sheet1.xml" "worksheet.sheetViews[0].sheetView"}} <sheetView tabSelected="1" workbookViewId="0"> <pane ySplit="1" topLeftCell="A2" activePane="bottomLeft" state="frozen"/> </sheetView> {{/xlsxAdd}}
Playground example
https://playground.jsreport.net/w/anon/nJiWyZq9