Locked Excel Cells Becoming Unlocked When Re Opened

90 Views Asked by At

I have a Blueprism process which is locking a column and protecting the worksheet. The cells are then locked. When the file is saved, closed and re opened the cells are no longer locked.

GetInstance(handle).Activecell.Locked = True
GetInstance(handle).ActiveSheet.Protect
2

There are 2 best solutions below

2
On BEST ANSWER

Issue was I was using a CSV. Doesn't seem to work there but does in a standard Excel Workbook.

1
On

Most of these cases are related to excel Settings, not exactly the Blueprism. I would suggest trying with Options Menu in Excel workbook and Remove Recovery flags as well.

Control+A and format sheet to Text Type and Save Manually First(One Time activity). Sometimes Formatting can be the root cause.