View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
William[_2_] William[_2_] is offline
external usenet poster
 
Posts: 227
Default Selection of non-empty cells

Hi keepITcool

Good point.

For the benefit of the OP, he should change the [a:a] in your code to
something like [a:iv] or use the used range.
--
XL2002
Regards

William



"keepITcool" wrote in message
...
|
| William,
|
| your code will throw an error
| if constants OR formulas OR both are are not found.
|
| i've posted one with a few more checks :)
|
| --
| keepITcool
| |
www.XLsupport.com | keepITcool chello nl | amsterdam
|
|
| William wrote :
|
| Hi Adrian
|
| Sub test()
| Dim r As Range
| Set r = Union(Cells.SpecialCells(xlCellTypeConstants, 23), _
| Cells.SpecialCells(xlCellTypeFormulas, 23))
| r.Select
| End Sub
|