Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
not pulling down formulas
Hi,
If anyone knows an alternative to pulling down 30 columns of formulas through 10,000 rows of new data, please, please, please let me know. Regards, Tim |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
not pulling down formulas
Tom,
Thank you for responding. To clarify, I am bringing in 5,000 - 10,000 rows of data calculated from another sheet. The existing data goes through column "AN", the formulas I have been pulling down make new calculations from the data in columns "A" - "AN". The column I am pulling the formulas down to is initially empty except for the first rows, which have headings and one row of formulas from the previous data. If I understand you correctly, I would change A2 in the macro to the first cell address that I would need to pull down formulas, "AM11"? The last column with formulas to pull down is "CS". That is "AM" through "CS" are all being pulled down. Please advise. Regards, Tim -----Original Message----- Sub Tester1() Range("A2").Resize(1, 30).Copy _ Destination:=Range("A2").Resize(10001, 30) End Sub Might do what you want if your formulas are constructed appropriately. Since you say through rows of data, then you might have to go a column at a time if the new columns are not contiguous. If you are adding columns to the end of your data, change A2 to the second row of the first column. -- Regards, Tom Ogilvy _______Tim_______ wrote in message ... Hi, If anyone knows an alternative to pulling down 30 columns of formulas through 10,000 rows of new data, please, please, please let me know. Regards, Tim . |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
not pulling down formulas
Sounds like you don't have any data in column AN. (although you said there
is). If you do have data in AN11 (with no blank cells) and it goes below row 11, then either method should work. If you don't, then you the non code method won't work and the code would have to be told specifically how many rows. Sub Tester1() Range("AM11:CS11").Copy _ Destination:=Range("AM11").Resize(10000, 59) End Sub -- Regards, Tom Ogilvy _______Tim_______ wrote in message ... Tom, You are right, 59 is allot different than 30. At first I was most concerned about the first thirty columns. When I run the macro I get a "Run-time error '1004': Application-defined or object- defined error" in the line Range("AM11:CS11").Copy _ Destination:=Range("AM11").Resize(rng.row-10, 59) Also, I have tried the double click on the lower right square and it does not work in my Excel 2000 Professional. Please advise. Regards, Tim -----Original Message----- If your formulas are in AM11:CS11 Sub Tester1() set rng = Cells(rows.count,"AN").End(xlup) Range("AM11:CS11").Copy _ Destination:=Range("AM11").Resize(rng.row-10, 59) End Sub AM:CS is 59 columns Another way, without a macro, is to select AM11:CS11 then in the highlight you will see a small square in the lower right corner. Doubleclick on that square and your formulas should fill down to the bottom of the data in column AN. -- Regards, Tom Ogilvy _______Tim_______ wrote in message ... Tom, Thank you for responding. To clarify, I am bringing in 5,000 - 10,000 rows of data calculated from another sheet. The existing data goes through column "AN", the formulas I have been pulling down make new calculations from the data in columns "A" - "AN". The column I am pulling the formulas down to is initially empty except for the first rows, which have headings and one row of formulas from the previous data. If I understand you correctly, I would change A2 in the macro to the first cell address that I would need to pull down formulas, "AM11"? The last column with formulas to pull down is "CS". That is "AM" through "CS" are all being pulled down. Please advise. Regards, Tim -----Original Message----- Sub Tester1() Range("A2").Resize(1, 30).Copy _ Destination:=Range("A2").Resize(10001, 30) End Sub Might do what you want if your formulas are constructed appropriately. Since you say through rows of data, then you might have to go a column at a time if the new columns are not contiguous. If you are adding columns to the end of your data, change A2 to the second row of the first column. -- Regards, Tom Ogilvy _______Tim_______ wrote in message ... Hi, If anyone knows an alternative to pulling down 30 columns of formulas through 10,000 rows of new data, please, please, please let me know. Regards, Tim . . |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
not pulling down formulas
I am not sure what you mean by too large.
It can be done a column at a time Sub Tester1() Dim numRows as Long Dim cell as Range numRows = Activesheet.Usedrange.rows.count - 10 for each cell in Range("AM11:CS11") cell.copy Destination:=cell.Resize(numRows, 1) End Sub -- Regards, Tom Ogilvy _______Tim_______ wrote in message ... Tom, You are right again. Column AN is used to update data and with the update some of the formula results to the right will change. Sorry about that. I just don't know what information you need to know. Besides, I put data in column AN and tried to run the macro but the area is too large. Could this be accomplished one column at a time and then the next column etc.? Thanks again. Regards, Tim -----Original Message----- Sounds like you don't have any data in column AN. (although you said there is). If you do have data in AN11 (with no blank cells) and it goes below row 11, then either method should work. If you don't, then you the non code method won't work and the code would have to be told specifically how many rows. Sub Tester1() Range("AM11:CS11").Copy _ Destination:=Range("AM11").Resize(10000, 59) End Sub -- Regards, Tom Ogilvy _______Tim_______ wrote in message ... Tom, You are right, 59 is allot different than 30. At first I was most concerned about the first thirty columns. When I run the macro I get a "Run-time error '1004': Application-defined or object- defined error" in the line Range("AM11:CS11").Copy _ Destination:=Range("AM11").Resize(rng.row-10, 59) Also, I have tried the double click on the lower right square and it does not work in my Excel 2000 Professional. Please advise. Regards, Tim -----Original Message----- If your formulas are in AM11:CS11 Sub Tester1() set rng = Cells(rows.count,"AN").End(xlup) Range("AM11:CS11").Copy _ Destination:=Range("AM11").Resize(rng.row-10, 59) End Sub AM:CS is 59 columns Another way, without a macro, is to select AM11:CS11 then in the highlight you will see a small square in the lower right corner. Doubleclick on that square and your formulas should fill down to the bottom of the data in column AN. -- Regards, Tom Ogilvy _______Tim_______ wrote in message ... Tom, Thank you for responding. To clarify, I am bringing in 5,000 - 10,000 rows of data calculated from another sheet. The existing data goes through column "AN", the formulas I have been pulling down make new calculations from the data in columns "A" - "AN". The column I am pulling the formulas down to is initially empty except for the first rows, which have headings and one row of formulas from the previous data. If I understand you correctly, I would change A2 in the macro to the first cell address that I would need to pull down formulas, "AM11"? The last column with formulas to pull down is "CS". That is "AM" through "CS" are all being pulled down. Please advise. Regards, Tim -----Original Message----- Sub Tester1() Range("A2").Resize(1, 30).Copy _ Destination:=Range("A2").Resize(10001, 30) End Sub Might do what you want if your formulas are constructed appropriately. Since you say through rows of data, then you might have to go a column at a time if the new columns are not contiguous. If you are adding columns to the end of your data, change A2 to the second row of the first column. -- Regards, Tom Ogilvy _______Tim_______ wrote in message ... Hi, If anyone knows an alternative to pulling down 30 columns of formulas through 10,000 rows of new data, please, please, please let me know. Regards, Tim . . . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel formulas pulling from another worksheet changes when sorted | Excel Worksheet Functions | |||
formulas pulling data from other worksheets | Excel Discussion (Misc queries) | |||
Spreading formulas down the workbook while pulling from 2nd workbo | Excel Discussion (Misc queries) | |||
Formulas pulling from other tables | Excel Worksheet Functions | |||
Pulling out every nth value | Excel Worksheet Functions |