Hello,
This is my first post here. This is a cross post. I read that cross posts are frowned on, but I didn't receive any replies to the second part of my query and what I am trying to do is beyond my (current) abilities. So I'm hoping that this is ok to post. See the following link.
http://www.mrexcel.com/forum/showthread.php?t=413309
Here is the first part of my question. I did get a response and solution to this.
Part 1.
Here's the scenario. Worksheet with data in range A3:K58. Note that the range will always start on row 3, but it is possible that the range might increase from time to time with additional rows. I want to do 2 things.
First, I want to go thru the range and remove any blank rows.
Second, I want to go thru the range from top to bottom and insert a single blank row conditionally. The condition is as follows: Column K is a "check sum" sort of column. It will have a non-zero value at the top, and at some point (row) the value in this column will change to zero and be zero after that for the rest of the range. (An enhancement would be to verify that this is indeed the case.) All I need to do is to insert a blank row above the first row that has a zero in column K.
Here is the second part of my question. I did not get a response and solution to this.
Part 2:
Now if someone could further help me to learn and better error-proof things...
1) It's unlikely but possible that column K could change. eg If someone inserts a column ahead of it, turning it into L. How can I deal with this? Some sort of relative reference, or naming column K as a range?
2) Error check that column K does indeed have the structure expected. (See my first post.) That is, starting at row 3, it should have a non-zero value to 'some' row, then it should change to zero and remain zero for all subsequent rows. I would want to perform this check first. If all is ok, continue. If not, stop and provide message.
Thanks in advance.
Bookmarks