Formula for duplicating cells

majesticgiftware

New Member
Joined
Jul 28, 2011
Messages
5
Hi

I have 2 columns with info. The first column is a quantity and the second is an item number. I am looking for a formula that will create new cells with item numbers in the quantities that are in the first column.

Any help will be greatky appreciated.
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
What does this mean exactly:
"I am looking for a formula that will create new cells with item numbers in the quantities that are in the first column"?

Formulas do not create new cells, they only return results in the cell they occupy.

Maybe you need a pivot table or a SUMIF or SUMPRODUCT or something else. Try explaining with examples of your data and which cells that data is in, and what your expected results are based on what criteria logic.
 
Upvote 0
Hi

I have 2 columns with info. The first column is a quantity and the second is an item number. I am looking for a formula that will create new cells with item numbers in the quantities that are in the first column.
Any help will be greatky appreciated.

I wonder if you want a list of unique item numbers in a column and sum of their quantities?
 
Upvote 0
Sorry if I was unclear. Here is an example.
<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>
Column 1 Column 2 Column 3
Qty Item Formula
3 Pen Pen
3 Watch Pen
3 Plate Pen
Watch
Watch
Watch
Plate
Plate
Plate
My objective is to mutiply items by the quantity and this would be created in the column containing the formula. Is this possible?

I can't get the columns to display properly here but the last 3 watches and the last 3 plates should be under the 3 pens on the right sid in column 3
 
Last edited:
Upvote 0
Sorry if I was unclear. Here is an example.
<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>
Column 1 Column 2 Column 3
Qty Item Formula
3 Pen Pen
...
With
3 Pen Pen
in Column 1
So you want like this in Column 3 ?:
Pen Pen
Pen Pen
Pen Pen
 
Upvote 0
Sorry if I was unclear. Here is an example.
<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>
Column 1 Column 2 Column 3
Qty Item Formula
3 Pen Pen
3 Watch Pen
3 Plate Pen
Watch
Watch
Watch
Plate
Plate
Plate
My objective is to mutiply items by the quantity and this would be created in the column containing the formula. Is this possible?

I can't get the columns to display properly here but the last 3 watches and the last 3 plates should be under the 3 pens on the right sid in column 3
Try this...

Book1
ABC
23PenPen
33WatchPen
43PlatePen
5__Watch
6__Watch
7__Watch
8__Plate
9__Plate
10__Plate
11__
Sheet1

Create this named formula:
  • Name: Array
  • Refers to: =ROW(INDIRECT("1:3"))
Then, this array formula** entered in C2:

=IF(ROWS(C$2:C2)>SUM(A$2:A$4),"",INDEX(B$2:B$4,MIN(IF(SUBTOTAL(9,OFFSET(A$2,,,Array))>=ROWS(C$2:C2),Array))))

** array formulas need to be entered using the key
combination of CTRL,SHIFT,ENTER (not just ENTER).
Hold down both the CTRL key and the SHIFT key
then hit ENTER.

Copy down until you get blanks.

The named formula, Array, refers to the number of items in the list. In your list there are 3 items: Pen, Watch, Plate. So:

=ROW(INDIRECT("1:3"))
 
Upvote 0
Try using some helper cells like this.

Formula in E2 copied down at least as far as the data in columns A:B.
Formula in C2 copied down as far as you are ever likely to need (at least as many rows as the value in F1, but it can be further)

Excel Workbook
ABCDEF
1QtyItemFormulaCum Qty10
23PenPen1
34WatchPen4
43PlatePen8
5Watch
6Watch
7Watch
8Watch
9Plate
10Plate
11Plate
12
Replicate Values
 
Upvote 0
Try using some helper cells like this.

Formula in E2 copied down at least as far as the data in columns A:B.
Formula in C2 copied down as far as you are ever likely to need (at least as many rows as the value in F1, but it can be further)

Excel Workbook
ABCDEF
1QtyItemFormulaCum Qty10
23PenPen1
34WatchPen4
43PlatePen8
5Watch
6Watch
7Watch
8Watch
9Plate
10Plate
11Plate
12
Replicate Values



Worked perfectly. Thnx.
 
Upvote 0

Forum statistics

Threads
1,224,509
Messages
6,179,192
Members
452,893
Latest member
denay

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top