Simple seach and copy help needed
hi, I'm a noob at programming and this should be a breeze for the
gurus. I need to search down a column for values 100000 and if found, copy the whole row to sheet 2. It should loop through all the data in the table until the last row. simple as that. thanks!! |
Simple seach and copy help needed
Sub Macro1()
Dim iCt As Integer Dim iRow1 As Integer Dim iRow2 As Integer iRow1 = Sheets(1).Range("A65536").End(xlUp).Row For iCt = 1 To iRow1 If Sheets(1).Cells(iCt, 1) 10000 Then iRow2 = iRow2 + 1 Sheets(1).Rows(iCt).Copy Sheets(2).Rows(iRow2) End If Next iCt End Sub Hth, Merjet |
All times are GMT +1. The time now is 01:02 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com