Hello,
I have a snippet of code here that should do the following:
1) Place a simple "IF" formula in Row X of Column B. The IF formula does the following:
-Compares value in Row x of Column D to value of Row x+1 of Column D (So D4 and D5 for example)
-If values are the same, leave row in Column B blank or empty
-If values are different put a "1" in Row X of Column B.
(so, if D5 was different than D4, cell B4 would get a "1")
2) For every row where there is a "1", the Macro should
-Insert a row beneath the row containing the "1"
Example: "WHAT IT SHOULD DO..."
BEFORE:
D4 Apples
D5 Oranges
D6 Oranges
D7 Bananas
D8 Grapes
D9 Cherries
AFTER:
D4 Apples
D5
D6 Oranges
D7 Oranges
D8
D9 Bananas
D10
D11 Grapes
D12
D13 Cherries
Now, for some reason, the macro only does the very first run through correctly, but after that, it does almost the COMPLETE OPPOSITE of what it should do.
It inserts blank rows underneath one another over and over and then it only sporadically inserts a blank row between the values in Column D that are different from the value in the row above it, missing multiple different values in the process.
Example: "WHAT IT IS DOING..."
BEFORE:
D4 Apples
D5 Oranges
D6 Oranges
D7 Bananas
AFTER:
D4 Apples:
D5
D7 Oranges
D8 Oranges
D9
D10
D11
D14 Bananas
D15 Grapes
D16 Cherries
Really could use some help with this one please.Please Login or Register to view this content.
Thanks,
R.J.
Bookmarks