Copy text from cell below based on condition
Solved/Closed
Related:
- Copy text from cell below based on condition
- Excel conditional formatting if another cell contains specific text ✓ - Excel Forum
- Instagram account based in wrong country - Instagram Forum
- Based on the values in cells b77 ✓ - Excel Forum
- Excel macro to create new sheet based on value in cells - Guide
- Clear only the formatting from the selected cell (leaving the content) - Guide
1 response
venkat1926
Posts
1863
Registration date
Sunday June 14, 2009
Status
Contributor
Last seen
August 7, 2021
811
Apr 15, 2010 at 07:22 AM
Apr 15, 2010 at 07:22 AM
your sample data is like this from A1 down
***
text
***
text2
try this macro
As you are messing up with the data please save the original data safely somewhere.
***
text
***
text2
try this macro
Sub test() Dim r As Range, c As Range Set r = Range(Range("A1"), Cells(Rows.Count, "A").End(xlUp).Offset(-1, 0)) For Each c In r If c = "***" Then c = c.Offset(1, 0) End If Next c End Sub
As you are messing up with the data please save the original data safely somewhere.
Apr 15, 2010 at 08:12 AM
Thanks very much,
Paul