Using xlwt I can't see how to protect a worksheet, yet allow
formatting of cells, columns, rows, as you can do when applying
worksheet protection in the Excel 2003 UI. I would have guessed that
you would set:
sheet.protect = True
and
sheet.wnd_protect = False
but that seems to have no effect, at least on this score.
> Using xlwt I can't see how to protect a worksheet, yet allow > formatting of cells, columns, rows, as you can do when applying > worksheet protection in the Excel 2003 UI. I would have guessed that > you would set:
> sheet.protect = True
> and
> sheet.wnd_protect = False
> but that seems to have no effect, at least on this score.
That would be because "window protection" relates to the whole physical display window.
When I do Tools/Protection/Sheet in the Excel 2003 UI, it pops up a pane with a separate tickbox for each of a whole lot of things including format cells, format columns, format rows. Doesn't look like a single bit will cover all of that.
Rummaging in the docs leads to what MS call the FeatHdr (feature header) record which was introduced in Excel 10. A subset of the functionality is described in the OOo docs as the "SHEETPROTECTION" record.