Consulting

Results 1 to 2 of 2

Thread: Can't Get Find Method to Work

  1. #1

    Can't Get Find Method to Work

    Hi all,

    I have a suspicion I'm about to be found out for the idiot I surely am, but, here goes. Can anyone see what is wrong with the statement below? It lies within a For...Next loop for lngReqtRow and is attempting to cycle though the instances of lngReqtRow and on each step to run a search for a match in (a defined) rngSearchRange which lies in another file (the search file is open by the time this line runs). On running, I get Error 2023 associated with the 'wsReqts.Cells(lngReqtRow,2)' part. All variables are defined properly. I'm afraid I can't post the entire workbook but can provide more of the code if that's useful to anyone.

    Set rngMatch = rngSearchRange.Find(what:=wsReqts.Cells(lngReqtRow, 2), LookIn:=xlValues, LookAt:=xlWhole)

    Any help would be really welcome! TIA

  2. #2
    Sorry, sorry. I have found myself out. The cell being matched had a #REF error in it. Ignore me.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •