Up...
How it works...![]()
ActiveCell.EntireColumn.Find("", ActiveCell, xlValues, , , 2).Select
The .Find method
Or select Find in your code and press F1 for help.
Up...
How it works...![]()
ActiveCell.EntireColumn.Find("", ActiveCell, xlValues, , , 2).Select
The .Find method
Or select Find in your code and press F1 for help.
Surround your VBA code with CODE tags e.g.;
[CODE]your VBA code here[/CODE]
The # button in the forum editor will apply CODE tags around your selected text.
Thanks AlphaFrog!
I even now have found another method that better covers my needs. I just leave it here in case could help somebody:
GO DOWN
GO UP:![]()
Sub down () Dim startTime As Date startTime = Now ActiveCell.Offset(1, 0).Select Do Until ActiveCell.EntireRow.Hidden = False ActiveCell.Offset(1, 0).Select If DateDiff("s", startTime, Now) > 0.5 Then ActiveCell.End(xlDown).Select Exit Do End If Loop End sub
Is basically the same code I had, but now I have added a condition that when the loop takes more than 0.5 seconds, stops the loop and goes directly to the next empty visible row![]()
Sub Up () Dim startTime As Date startTime = Now ActiveCell.Offset(-1, 0).Select Do Until ActiveCell.EntireRow.Hidden = False ActiveCell.Offset(-1, 0).Select If DateDiff("s", startTime, Now) > 0.5 Then ActiveCell.End(xlup).Select Exit Do End If Loop End sub
![]()
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks