View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Don Guillett[_4_] Don Guillett[_4_] is offline
external usenet poster
 
Posts: 2,337
Default Setting a range using VBA

try

Sub selectit()
x = ActiveSheet.UsedRange.Rows.Count
Range(Cells(2, 1), Cells(x, 1)).Select
End Sub
--
Don Guillett
SalesAid Software

" wrote in message
...
How can I goto A2 then emulate the keystrokes [Control]
[Shift][End] then [Shift][Home] tocapture column A for
the height of the data using VBA?
Thanks