View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Bernie Deitrick Bernie Deitrick is offline
external usenet poster
 
Posts: 5,441
Default Select variably-sized range which contains empty cells

Jean,

Try:

..Range("G:H").SpecialCells(xlCellTypeBlanks).Valu e = "offen" '
..Range("G4").End(xlDown)(-1, 1).Resize(3, 1).ClearContents

HTH,
Bernie
MS Excel MVP


"Jean" wrote in message
oups.com...
Thanks for both your quick replies. I went with Bernie's solution and
it works great.

All I need to do is now delete the bottom 3 cells in my range, they
should not have "Open" in them.
I was thinking that one should use the following, but how do I select a
range with Offset?

.Range("G:H").SpecialCells(xlCellTypeBlanks).Value = "offen" '
works great
.Range("g4").End(xlDown).Select
.Selection.Offset(-1, 0).Select
'How do I select a range from an offset witout using actual
cell/range references
.Selection.ClearContents

Thanks again!