Dim rngFound As Range Dim strFirst As String Set rngFound = DataMatchSht.Columns("B").Find("CNH MXI", Cells(Rows.Count, "B"), xlValues, xlWhole) If Not rngFound Is Nothing Then strFirst = rngFound.Address Do 'Found a match Debug.Print "Found a match at: " & rngFound.Row & Chr(10) & _ "Value in column C: " & Cells(rngFound.Row, "C").Value & Chr(10) & _ "Value in column D: " & Cells(rngFound.Row, "D").Value Set rngFound = Columns("CNH MXI").Find(strID, rngFound, xlValues, xlWhole) Loop While rngFound.Address <> strFirst End If
标签:vba,某列,Cells,Value,strFirst,Chr,列和行,rngFound,Row From: https://www.cnblogs.com/Insist-Y/p/16996074.html