S
SteveDB1
Hi all.
On one of my macros, I want to set it up to run through a single sheet until
it finds the last row of contents.
However, I want it to only do select cells, that are bounded by borders.
I.e., instead of my having to activate for each cell group, I'd like to
I thought something like this would do it, but I'm missing something.
dim i as integer
dim myRng as range
for i = 1 to lastcell ' where lastcell is the last row with data.
set myRng = nothing
set myRng = ?
if myRng.Border(xlEdgeBottom) <> true then
Run "MyMacro"
Else : myRng.cells(?) = offset (1,0) 'down one row, zero columns
end if
next i
I'm sure something needs to be stated differently, I just haven't figured
out what, yet.
Thank you.
Best.
On one of my macros, I want to set it up to run through a single sheet until
it finds the last row of contents.
However, I want it to only do select cells, that are bounded by borders.
I.e., instead of my having to activate for each cell group, I'd like to
I thought something like this would do it, but I'm missing something.
dim i as integer
dim myRng as range
for i = 1 to lastcell ' where lastcell is the last row with data.
set myRng = nothing
set myRng = ?
if myRng.Border(xlEdgeBottom) <> true then
Run "MyMacro"
Else : myRng.cells(?) = offset (1,0) 'down one row, zero columns
end if
next i
I'm sure something needs to be stated differently, I just haven't figured
out what, yet.
Thank you.
Best.