conditional row delete
Posted on 2013-10-23
I have a worksheet with X number of columns (this can run up to 200 columns or more), but the exact number is variable. So, first have to calculate number of rows that happen to be in this particular worksheet.
Then, I want to go through each row and check the value initially in the the ninth column (I), then every 12 columns (U, AG...) thereafter to the end. The number of the last column having been determined in step 1 above. However, the end column will not be the last column checked. The last column will be about 4 columns after the last column checked. For example, because we are checking every 12 columns after column I, the last checked column ( I know this for certain ) will not be the last column in the worksheet, but will be about 4 columns before the end.
For a given row, if all values in all columns that were checked were below 2 and less than -2 (between 2 and -2), then delete the row.