我進行了大量的研究,并找到了部分對我有用的代碼。
我想要的只是一個簡單地轉到下面的下一個單元格但行被過濾的代碼。
這段代碼的問題在于它會轉到第一行(標題),然后偏移到下一行。
With ActiveSheet.AutoFilter.Range
Range("E" & .Offset(1, 0).SpecialCells(xlCellTypeVisible)(1).Row).Select
End With
我希望代碼能做到這一點,但行不是連續的:

uj5u.com熱心網友回復:
我為你搜索了它!
Sub GoToNextVisibleCellBelow()
Do
ActiveCell.Offset(1, 0).Select
Loop While ActiveCell.EntireRow.Hidden = True
End Sub
uj5u.com熱心網友回復:
我花了一整夜在谷歌搜索和閱讀有關Do While使用的想法的檔案ActiveCell.EntireRow.Hidden = True,最后的想法是:
ActiveCell.Offset(1, 4).Activate 'because I want to activate column "E" Do While ActiveCell.EntireRow.Hidden = True ActiveCell.Offset(1, 0).Activate Loop
它就像一個魅力。
我希望它對社區有所幫助。??
轉載請註明出處,本文鏈接:https://www.uj5u.com/shujuku/415402.html
標籤:
