View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
dominicb[_22_] dominicb[_22_] is offline
external usenet poster
 
Posts: 1
Default Hide Rows From a Row to Last usedCell.Row


Good evening Helmekki

Slight departure from your code, but it's neat and seems to work OK.
It actually hides the rows from the currently active cell row right u
to the last row containing information.

Sub Test()
lastrow = ActiveSheet.UsedRange.Rows.Count + 1
nowrow = ActiveCell.Row + 1
For f = nowrow To lastrow
Rows(f).Select
Selection.EntireRow.Hidden = True
Next f
End Sub

Is that any good to you?

HTH

Dominic

--
dominic
-----------------------------------------------------------------------
dominicb's Profile: http://www.excelforum.com/member.php...fo&userid=1893
View this thread: http://www.excelforum.com/showthread.php?threadid=37783