hide range of rows based on another cell condition

D

Don Guillett

sub hideem()
if len(application.trim(range("i8")))<1 then
rows ("5:30").hidden=true
end if
end sub
 
R

ryguy7272

Try this:
Sub Hide()
If Range("I8") = "" Then
Rows("5:30").RowHeight = 0
End If
End Sub


Sub Unhide()

Cells.Select
Selection.RowHeight = 12.75
End Sub

HTH,
Ryan---
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top