I am using VBA to search an Excel sheet. It will need to loop through column B for a cell containing two values. I have tried a Do Until and If statements, but it will only find the first value and return that cell. This is an issue because there may be multiple cells with the first value but only one cell with the second value. Is there a way to search for the two values at the same time? or Loop through each cell until it finds both values?

I have tried multiple different codings and ways, I have yet it to find the correct cell for both values. Like I said, it'll find the first cell it comes to containing the first value but cannot get it to loop to the first cell containing both values?


Do Until sCheck = True And dCheck = True
         
         Set foundSite = objSheet.Range("B:B").Find(sN)
         atRow = foundSite.Address
         
         Set foundData = objSheet.Range(atRow).Find(dT)
        
         atRow1 = foundData.Address
         verMsg = MsgBox(atRow1, vbOKOnly, "FOUND")
         
         If Not foundSite = Empty And Not foundData = Empty Then
                  
         sCheck = True
         dCheck = True
                  
         End If
         Loop
This is an example of what I was trying to do. It would find a cell containing first value but cannot get it to only find the cell containing both. Thanks for any help in advance.