View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
Gary''s Student Gary''s Student is offline
external usenet poster
 
Posts: 11,058
Default Selecting cells on active row

Sub GetBlock()
Dim L As Long
L = ActiveCell.Row
Range("A" & L & ":H" & L).Select
End Sub

This will Select A thru H in the row with the ActiveCell.
--
Gary''s Student - gsnu200855


"merry_fay" wrote:

Hi,

Having used a macro to get the first cell on the row I need selected, how do
I then get it to select the range A:H or even the entire row? I can't do
xlright as there may be blanks in some columns.

Also, is there a way of getting the macro to select a cell with a specific
word in it? I've managed a work-around but it would be nicer to use more
specific, neat code

Thanks
merry_fay