Set a Range to all of the first row
I assume you would like to use different variable names.
Dim rngSearchRow1 as Range
Dim rngSearchColumn1 as Range
Dim Z as Long
Z = 1
set rgnSearchRow1 = workbooks("Book1.xls").Worksheets(Z).rows(1).Cells
set rngSearchColumn1 = workbooks("Book1.xls").Worksheets(Z).Columns(1).Ce lls
--
Regards,
Tom Ogilvy
"Kevin McCartney" wrote in message
...
I'd like to do two things, set a range to all of row one
and set a second range to all of column A
Please help with the correct code to use. currently I have
Set rgeSearch1 = Application.Worksheets(Z).column(1)
Set rgeSearch1 = Application.Worksheets(Z).rows(1)
Thanks
Best regards
KM
|