S
SS
I am trying to run an If..Then sequence that will look at
the value (Text Value) in Cell A1 and A4 and if they are
not equal insert a line on one side or the other.
For Example the following:
AB AB
AB AB
AB BC
BC BC
....
Would look like:
AB AB
AB AB
AB
BC BC
BC
....
So Far I have:
If Worksheets(5).Cells(Count, 1).Value > Worksheets
(5).Cells(Count, 4).Value Then
Worksheets(5).Range(Cells(Count, 1), Cells(Count,
2)).Insert Shift:=xlDown
ElseIf Worksheets(5).Cells(Count, 1).Value < Worksheets
(5).Cells(Count, 4).Value Then
Worksheets(5).Range(Cells(Count, 4), Cells(Count,
5)).Insert Shift:=xlDown
End If
This does not work. It will keep inserting lines and
never stagger the cells.
Does anyone have any ideas?
Thank you
SS
the value (Text Value) in Cell A1 and A4 and if they are
not equal insert a line on one side or the other.
For Example the following:
AB AB
AB AB
AB BC
BC BC
....
Would look like:
AB AB
AB AB
AB
BC BC
BC
....
So Far I have:
If Worksheets(5).Cells(Count, 1).Value > Worksheets
(5).Cells(Count, 4).Value Then
Worksheets(5).Range(Cells(Count, 1), Cells(Count,
2)).Insert Shift:=xlDown
ElseIf Worksheets(5).Cells(Count, 1).Value < Worksheets
(5).Cells(Count, 4).Value Then
Worksheets(5).Range(Cells(Count, 4), Cells(Count,
5)).Insert Shift:=xlDown
End If
This does not work. It will keep inserting lines and
never stagger the cells.
Does anyone have any ideas?
Thank you
SS