HI all
I have a formula in cell J2 that needs to be copied down to fill the
rest of column J. The problem is that the number of rows in the
worksheet will vary from month to month.
How do I indicate in the macro that the last row will vary? Thanks
HI all
I have a formula in cell J2 that needs to be copied down to fill the
rest of column J. The problem is that the number of rows in the
worksheet will vary from month to month.
How do I indicate in the macro that the last row will vary? Thanks
Find the last row first
sub FillDownInJ()
dim lngLastRow as long
lngLastRow=Cells(rows.count,"J").end(xlup).Row
Range("J2:J" & lngLastRow).filldown
end sub
lastrow=cells(rows.count,"j").end(xlup).row
--
Don Guillett
SalesAid Software
donaldb@281.com
"JTF" <jtfreed@email.uncc.edu> wrote in message
news:1124719098.008671.238100@g43g2000cwa.googlegroups.com...
> HI all
>
> I have a formula in cell J2 that needs to be copied down to fill the
> rest of column J. The problem is that the number of rows in the
> worksheet will vary from month to month.
>
> How do I indicate in the macro that the last row will vary? Thanks
>
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks