Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Dynamic Autofill Error
I have a piece of code that does a dynamic autofill and it usually works wonderfully. I just added it to a report that I'm working on, and I got the 1004 runtime error, "Application defined or object-defined error".
Here is my code: Code:
NumberofRows = Cells(Rows.Count, "B").End(xlUp).Row 'Choose column letter that has last row of data Range("A2").Select ActiveCell.Autofill Range(ActiveCell, Cells(NumberofRows, _ ActiveCell.Column - 1).Offset(, 1)) Any help is appreciated! |
#2
|
|||
|
|||
Quote:
|
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Dynamic Autofill Error
Hi,
Am Thu, 18 Oct 2012 14:15:10 +0000 schrieb KeriM: NumberofRows = Cells(Rows.Count, "B").End(xlUp).Row 'Choose column letter that has last row of data Range("A2").Select ActiveCell.Autofill Range(ActiveCell, Cells(NumberofRows, _ ActiveCell.Column - 1).Offset(, 1)) try: NumberOfRows = Cells(Rows.Count, "B").End(xlUp).Row Range("A2").AutoFill Range(Cells(2, 1), Cells(NumberOfRows, 1)) Regards Claus Busch -- Win XP PRof SP2 / Vista Ultimate SP2 Office 2003 SP2 /2007 Ultimate SP2 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Dynamic Autofill | Excel Discussion (Misc queries) | |||
Autofill Dynamic Range | Excel Programming | |||
autofill with dynamic lists | Excel Programming | |||
autofill with dynamic range | Excel Programming | |||
autofill with dynamic range again | Excel Programming |