If you get protection errors it may be that your code is trying to alterprotected parts of the workbook. The way to deal with this is, in your codeto turn protection off, make the changes, then turn protection back on.