How do you paste rows one under the other based on the number given in another sheet?
So, here's the thing. I have an excel workbook with two worksheets.
Worksheet 1: People tell me how many items they own per category.
Worksheet 2: People give me details for each item.
And I would like Worksheet 2 to already contain the rows, so they only have to add the details. So I basically want to prepopulate it.
Here is table 1 / Worksheet 1:
enter image description here
So I give people the ID and the category and they add the quantity
And here is table 2 / Worksheet 2:
That's what it should look like (I manually pasted the ID and the Category but the table should be prepopulated automatically)
I know you could do that with a Macro. But my organization doesn't really like Macros so I am looking for a formula.
I really appreciate your help on this!
Thanks,
B
excel excel-formula
add a comment |
So, here's the thing. I have an excel workbook with two worksheets.
Worksheet 1: People tell me how many items they own per category.
Worksheet 2: People give me details for each item.
And I would like Worksheet 2 to already contain the rows, so they only have to add the details. So I basically want to prepopulate it.
Here is table 1 / Worksheet 1:
enter image description here
So I give people the ID and the category and they add the quantity
And here is table 2 / Worksheet 2:
That's what it should look like (I manually pasted the ID and the Category but the table should be prepopulated automatically)
I know you could do that with a Macro. But my organization doesn't really like Macros so I am looking for a formula.
I really appreciate your help on this!
Thanks,
B
excel excel-formula
add a comment |
So, here's the thing. I have an excel workbook with two worksheets.
Worksheet 1: People tell me how many items they own per category.
Worksheet 2: People give me details for each item.
And I would like Worksheet 2 to already contain the rows, so they only have to add the details. So I basically want to prepopulate it.
Here is table 1 / Worksheet 1:
enter image description here
So I give people the ID and the category and they add the quantity
And here is table 2 / Worksheet 2:
That's what it should look like (I manually pasted the ID and the Category but the table should be prepopulated automatically)
I know you could do that with a Macro. But my organization doesn't really like Macros so I am looking for a formula.
I really appreciate your help on this!
Thanks,
B
excel excel-formula
So, here's the thing. I have an excel workbook with two worksheets.
Worksheet 1: People tell me how many items they own per category.
Worksheet 2: People give me details for each item.
And I would like Worksheet 2 to already contain the rows, so they only have to add the details. So I basically want to prepopulate it.
Here is table 1 / Worksheet 1:
enter image description here
So I give people the ID and the category and they add the quantity
And here is table 2 / Worksheet 2:
That's what it should look like (I manually pasted the ID and the Category but the table should be prepopulated automatically)
I know you could do that with a Macro. But my organization doesn't really like Macros so I am looking for a formula.
I really appreciate your help on this!
Thanks,
B
excel excel-formula
excel excel-formula
edited Nov 15 '18 at 13:48
Adarsh
9110
9110
asked Nov 15 '18 at 10:20
PromeixcelPromeixcel
1
1
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
This solution does not require VBA.
In sheet 1:
Insert a new column at the beginning so that all the data is shifted one column to the right (A becomes B, B becomes C etc).
In cell
A2
,enter 1. Then inA3
enter=A2+D2
, then fill this formula down toA6
From
F1
toF6
, enter the numbers 1 to 6 consecutively (1 in F1, 2 in F2 etc)Hide column A and F
Now move to sheet 2
In cell
A2
, enter the formula=VLOOKUP(ROW(A2),Sheet1!$A$2:$C$5,2)
and fill it down toA6
In cell
B2
, enter the formula=VLOOKUP(ROW(B2),Sheet1!$A$2:$C$5,3)
and fill it down to B6
The formulas in sheet 2 can now be extended/filled down further as required to capture all the data in sheet 1.
The final result (sheet 2) looks like this:
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53317209%2fhow-do-you-paste-rows-one-under-the-other-based-on-the-number-given-in-another-s%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
This solution does not require VBA.
In sheet 1:
Insert a new column at the beginning so that all the data is shifted one column to the right (A becomes B, B becomes C etc).
In cell
A2
,enter 1. Then inA3
enter=A2+D2
, then fill this formula down toA6
From
F1
toF6
, enter the numbers 1 to 6 consecutively (1 in F1, 2 in F2 etc)Hide column A and F
Now move to sheet 2
In cell
A2
, enter the formula=VLOOKUP(ROW(A2),Sheet1!$A$2:$C$5,2)
and fill it down toA6
In cell
B2
, enter the formula=VLOOKUP(ROW(B2),Sheet1!$A$2:$C$5,3)
and fill it down to B6
The formulas in sheet 2 can now be extended/filled down further as required to capture all the data in sheet 1.
The final result (sheet 2) looks like this:
add a comment |
This solution does not require VBA.
In sheet 1:
Insert a new column at the beginning so that all the data is shifted one column to the right (A becomes B, B becomes C etc).
In cell
A2
,enter 1. Then inA3
enter=A2+D2
, then fill this formula down toA6
From
F1
toF6
, enter the numbers 1 to 6 consecutively (1 in F1, 2 in F2 etc)Hide column A and F
Now move to sheet 2
In cell
A2
, enter the formula=VLOOKUP(ROW(A2),Sheet1!$A$2:$C$5,2)
and fill it down toA6
In cell
B2
, enter the formula=VLOOKUP(ROW(B2),Sheet1!$A$2:$C$5,3)
and fill it down to B6
The formulas in sheet 2 can now be extended/filled down further as required to capture all the data in sheet 1.
The final result (sheet 2) looks like this:
add a comment |
This solution does not require VBA.
In sheet 1:
Insert a new column at the beginning so that all the data is shifted one column to the right (A becomes B, B becomes C etc).
In cell
A2
,enter 1. Then inA3
enter=A2+D2
, then fill this formula down toA6
From
F1
toF6
, enter the numbers 1 to 6 consecutively (1 in F1, 2 in F2 etc)Hide column A and F
Now move to sheet 2
In cell
A2
, enter the formula=VLOOKUP(ROW(A2),Sheet1!$A$2:$C$5,2)
and fill it down toA6
In cell
B2
, enter the formula=VLOOKUP(ROW(B2),Sheet1!$A$2:$C$5,3)
and fill it down to B6
The formulas in sheet 2 can now be extended/filled down further as required to capture all the data in sheet 1.
The final result (sheet 2) looks like this:
This solution does not require VBA.
In sheet 1:
Insert a new column at the beginning so that all the data is shifted one column to the right (A becomes B, B becomes C etc).
In cell
A2
,enter 1. Then inA3
enter=A2+D2
, then fill this formula down toA6
From
F1
toF6
, enter the numbers 1 to 6 consecutively (1 in F1, 2 in F2 etc)Hide column A and F
Now move to sheet 2
In cell
A2
, enter the formula=VLOOKUP(ROW(A2),Sheet1!$A$2:$C$5,2)
and fill it down toA6
In cell
B2
, enter the formula=VLOOKUP(ROW(B2),Sheet1!$A$2:$C$5,3)
and fill it down to B6
The formulas in sheet 2 can now be extended/filled down further as required to capture all the data in sheet 1.
The final result (sheet 2) looks like this:
answered Nov 15 '18 at 11:43
NickNick
98611332
98611332
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53317209%2fhow-do-you-paste-rows-one-under-the-other-based-on-the-number-given-in-another-s%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown