Ottsel
Board Regular
- Joined
- Jun 4, 2022
- Messages
- 167
- Office Version
- 365
- Platform
- Windows
Using a for loop to hide a section of rows, but this workbook I'm using is bound to Excel 2003 and the booklet is very large, which causes huge delays.
Currently, using the following, but it takes a long time and can cause the booklet to crash. Is there a way to make it so the rows are all selected at once and hidden?
Currently, using the following, but it takes a long time and can cause the booklet to crash. Is there a way to make it so the rows are all selected at once and hidden?
VBA Code:
dim i as integer
For i = 300 to 350
if cells(i,1).value = 0 then
cells(i,1).entirerow.hidden = true
else
cells(i,1).entirerow.hidden = false
end if
next i