I'm running Excel for Mac version 16.46. I have a .XLSM workbook with three worksheets, a small amount of data (approx 100 rows of data in each worksheet), and some VBA code that does some calculations when I enter new data rows. I have one subroutine that protects all but one row in the data entry worksheet to ensure that the user only enters data in one row at a time. The workbook file size is about 200KB, but when I run this subroutine one or more times, the file size increases to 102MB. I assume this problem is related to the fact that I'm protecting a huge block of cells (rows 1 - current row, and current row+1 - 65536). Is there a cleaner way of doing this? The code is pasted below. Thanks in advance for any help you can provide.
Moderator's note: Please take the time to review our rules. There aren't many, and they are all important. Rule #2 requires code tags. I have added them for you this time because you are a new member. --6StringJazzer
Bookmarks