Paste a formula in to a column for only certain number of rows

svelma

New Member
Joined
Aug 2, 2011
Messages
14
Hi,

I have a formula field say in C1(Concatenate(A1, B1)). I want to copy that formula on to the same or new column(C or D) but only till 13000 rows. If I just try pasting the formula by selecting the column on top, the formula gets pasted on 1048576(max) rows, which I don't want, as I just have 13k records in column A and B.
Is there a way I can select certain number of rows in a column(not by dragging as it is too much for 13k) and paste the formula on to it?

Thanks for your help.
 

Expiry

Well-known Member
Joined
Jun 20, 2007
Messages
865
If you're just after a quick and dirty way to do this, copy the formula into C13000 once, then drag it back up to row 1.
 

John Davis

Well-known Member
Joined
Sep 11, 2007
Messages
3,457
Hi,

I have a formula field say in C1(Concatenate(A1, B1)). I want to copy that formula on to the same or new column(C or D) but only till 13000 rows. If I just try pasting the formula by selecting the column on top, the formula gets pasted on 1048576(max) rows, which I don't want, as I just have 13k records in column A and B.
Is there a way I can select certain number of rows in a column(not by dragging as it is too much for 13k) and paste the formula on to it?

Thanks for your help.
A quick macro perhaps?

Code:
Sub svelma()

Range("C1:C13000").Formula = "=Concatenate(A1,B1)"

End sub
 

Forum statistics

Threads
1,082,116
Messages
5,363,251
Members
400,722
Latest member
DrewPop24

Some videos you may like

This Week's Hot Topics

  • populate from drop list with multiple tables
    Hi All, i have a drop list that displays data, what i want is when i select one of those from the list to populate text from different tables on...
  • Find list of words from sheet2 in sheet1 before a comma and extract text vba
    Hi Friends, Trying to find the solution on my task. But did not find suitable one to the need. Here is my query and sample file with details...
  • Dynamic Formula entry - VBA code sought
    Hello, really hope one of you experts can help with this - i've spent hours on this and getting no-where. .I have a set of data (more rows than...
  • Listbox Header
    Have a named range called "AccidentsHeader" Within my code I have: [CODE]Private Sub CommandButton1_Click() ListBox1.RowSource =...
  • Complex Heat Map using conditional formatting
    Good day excel world. I have a concern. Below link have a list of countries that carries each country unique data. [URL...
  • Conditional formatting
    Hi good morning, hope you can help me please, I have cells P4:P54 and if this cell is equal to 1 then i want row O to say "Fully Utilised" and to...
Top