Related:
- VBA return found cell value
- Vba case like - Guide
- Thunderbird return receipt - Guide
- Vba matrix multiplication - Excel Forum
- How to insert rows in excel automatically based on cell value without vba ✓ - Excel Forum
- Based on the cell values in cells b77 ✓ - Excel Forum
2 responses
venkat1926
Posts
1863
Registration date
Sunday June 14, 2009
Status
Contributor
Last seen
August 7, 2021
811
Sep 14, 2009 at 08:52 PM
Sep 14, 2009 at 08:52 PM
I wonder whether you can find values between two numbers by using "find" function.
anyhow try this macro
modify the macro to suit you. the relevant number data is in A1 down
The relevant rows are copied in sheet 2
anyhow try this macro
modify the macro to suit you. the relevant number data is in A1 down
The relevant rows are copied in sheet 2
Sub test()
Dim rng As Range, c As Range, dest As Range
With Worksheets("sheet1")
Set rng = Range(.Range("A1"), .Range("A1").End(xlDown))
For Each c In rng
If c >= 70 And c <= 71 Then
c.EntireRow.Copy
Else
GoTo line1
End If
With Worksheets("sheet2")
Set dest = .Cells(Rows.Count, "a").End(xlUp).Offset(1, 0)
dest.PasteSpecial
End With
line1:
Next c
End With
End Sub