Hi - can someone help me please. I have a number of columns that I wish to find in a spreadsheet so I repear the following on error resume next. But after it test's the cells.find it still copies the info and pastes it when I want it to ignore and to go to next test. Is there an easy way of doing this?

Many thanks


 On Error Resume Next
   
    test = Cells.Find(What:="RunID", After:=ActiveCell, LookIn:=xlFormulas, LookAt _
        :=xlWhole, SearchOrder:=xlByRows, SearchDirection:=xlNext, MatchCase:= _
        True, SearchFormat:=False).Activate
        If Not test = "" Then
        End If
       
    ActiveCell.Offset(1, 0).Select
    
    Range(Selection, Selection.End(xlDown).Offset(-1, 0)).Select
    Selection.Copy
    Windows("Excel Spreadsheet Header Row.xlsx").Activate
    Cells.Find(What:="RunID", After:=ActiveCell, LookIn:=xlFormulas, _
        LookAt:=xlWhole, SearchOrder:=xlByRows, SearchDirection:=xlNext, _
        MatchCase:=True, SearchFormat:=False).Activate
    ActiveCell.Offset(1, 0).Select
    Selection.PasteSpecial Paste:=xlPasteValuesAndNumberFormats, Operation:=xlNone, _
        SkipBlanks:=False, Transpose:=False
     Application.CutCopyMode = False

     
   ' next column and same run through as above
       
    Windows("PRE_amended.xlsx").Activate
    
     On Error Resume Next
    
    test = Cells.Find(What:="RunDate", After:=ActiveCell, LookIn:=xlFormulas, _
        LookAt:=xlWhole, SearchOrder:=xlByRows, SearchDirection:=xlNext, _
        MatchCase:=True, SearchFormat:=False).Activate
    ActiveCell.Offset(1, 0).Select
    Range(Selection, Selection.End(xlDown)).Select
    Selection.Copy
    Windows("Excel Spreadsheet Header Row.xlsx").Activate
    Cells.Find(What:="RunDate", After:=ActiveCell, LookIn:=xlFormulas, _
        LookAt:=xlWhole, SearchOrder:=xlByRows, SearchDirection:=xlNext, _
        MatchCase:=True, SearchFormat:=False).Activate
    If Not test = "" Then
    End If
    ActiveCell.Offset(1, 0).Select
    Selection.PasteSpecial Paste:=xlPasteValuesAndNumberFormats, Operation:=xlNone, _
        SkipBlanks:=False, Transpose:=False
    Application.CutCopyMode = False
    
    'Ee ref next column
    
    Windows("Pre_amended.xlsx").Activate
    
     On Error Resume Next