Copy text from cell below based on condition
Solved/Closed
        Related:         
- Copy text from cell below based on condition
 - If cell contains text then return value multiple conditions ✓ - Excel Forum
 - Excel conditional formatting based on date - Guide
 - Based on the cell values in cells b77 - Excel Forum
 - How to insert rows in excel automatically based on cell value without vba ✓ - Excel Forum
 - Excel add 1 if cell contains text ✓ - Excel Forum
 
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