返回列表 上一主題 發帖

如何選取"尋找"結果整列資料

如何選取"尋找"結果整列資料

各位高手:
小弟網路上找很久,

一直都找不到excel可以選取"尋找"結果整列資料的方法,

請問各位大大有何高見嗎?
so far so good

感謝高手,小弟馬上去試試,跪謝!
so far so good

TOP

VBA 以關鍵字搜尋刪除整列

各位高手,請問vba以關鍵字搜尋後刪除整列怎麼寫比較簡單?網路上寫得都很難,看不懂。
so far so good

TOP

各位高手:
小弟網路上找很久,

一直都找不到excel可以選取"尋找"結果整列資料的方法,

請問各位大大 ...
nmtaux 發表於 2016-4-2 22:25

試試:
  1. Sub nn()
  2.   With Range("a1:a500")
  3.     Set c = .Find(2, LookIn:=xlValues)
  4.     If Not c Is Nothing Then
  5.       firstAddress = c.Address
  6.       Do
  7.         c.EntireRow.Interior.ColorIndex = 8
  8.         Set c = .FindNext(c)
  9.       Loop While Not c Is Nothing And c.Address <> firstAddress
  10.     End If
  11.   End With
  12. End Sub
複製代碼

TOP

        靜思自在 : 【行善要及時】行善要及時,功德要持續。如燒開水一般,未燒開之前千萬不要停熄火候,否則重來就太費事了。
返回列表 上一主題