I'm writing sheets in xlwt with a header row and a few hundred data rows.
I'd like the header row to print at the top of every printed page, when I print from Excel.
Can I effect this setting from xlwt?
Thanks!
I've never seen a way to manipulate print settings with xlwt.
Unfortunately it doesn't appear possible to create a template excel file with the print settings and write the data to it.
If you're on windows, your best bet will probably be to use the pywin32 COM interface - create a template excel file that has your print settings, and write the data to it. I haven't used this (I'm on a mac), but supposedly it works the best.
You might test this strategy with openpyxl, which writes xlsx instead of xls. Previously it wouldn't maintain styles when editing documents, but now the style support has improved. I have no idea about whether it retains print settings.