# Auto Copy And Past

#### Seifeddine87

##### Board Regular
Hi just looking for how to make an auto copy and past
I have got all the data on my Stock sheet and when I go to sell sheets (from Jan to Dec) and put the item code in the sale sheet will copy Item Number Vehicles Category Parts Potition from stock sheet and past it in same row of sale sheet
Example
Stock sheet

…… ..A…………………B…………………..…C……………….……D…………..…..E…………………F…………….G
1…..Date……....Item Code……..Item Number……. Vehicles…….Category………Parts………Potition
2...02/12/16……..G52K51………033365258…………Clio…………….Body…..........Door………..FDS..
4...05/12/16……..G52H52………033385214…………Clio…………….Body…..........Door………..FPS..
5 .

Sale Sheets (From Jan to Dec)
…… ..A…………………B…………………..…C……………….……D…………..…..E…………………F…………….G
1…..Date……....Item Code……..Item Number……. Vehicles…….Category………Parts………Potition
3...28/12/16……..G52H52………033385214…………Clio…………….Body…..........Door………..FPS..
4...25/12/16……..G52K51………033365258…………Clio…………….Body…..........Door………..FDS..
5 .

Last edited:

### Excel Facts

Shade all formula cells
To shade all formula cells: Home, Find & Select, Formulas to select all formulas. Then apply a light fill color.

#### Scott T

##### Well-known Member
On the Sale sheet in cell C2 put the formula =VLOOKUP(\$B2,stock!\$B\$2:\$G\$4,COLUMNS(\$B2:C2),0) then copy across and down. Adjust cell references as need.

#### Scott T

##### Well-known Member
Is duplicate Item codes possible? The Vlookup formula will only return the first matching code that it finds.

#### Seifeddine87

##### Board Regular
thank you very much for your help no there is no duplicate on the cods

Replies
6
Views
1K
Replies
1
Views
854
Replies
11
Views
848
Replies
0
Views
1K
Replies
1
Views
199

1,191,166
Messages
5,985,051
Members
439,935
Latest member
Monty238

### 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?

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