Range objects (?)

B

Bill

Hello,
I have been having trouble defining a range of cells
when using objects. (If I am right, the counting cell is
my object) I have tried different approaches, but the
code below shows my latest failed attempt. How do you
specify a range of cells when you are using an object?
Here is my code:

Dim numberrow as long
Dim countingcell as object
numberrow = 5
Set countingcell = range("n4")
For cellcount = 0 to numberrow
If countingcell.offset(cellcount,0) = True Then
Worksheets("Sheets2").Range(Cells(cellcount,-3), Cells
(cellcount, -13)).select
etc....
Thanks
Bill
 
T

Tom Ogilvy

Dim numberrow as long
Dim countingcell as Range
Dim cellcount as Long
numberrow = 5
Set countingcell = range("n4")
For cellcount = 0 to numberrow
If countingcell.offset(cellcount,0) = True Then
countingCell.Offset(cellCount,-13).Resize(1,10).Select
msgbox "Take a look, click to continue . . . "
End if
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top