ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Macro Needed To Find Product Cost In Another Sheet (https://www.excelbanter.com/excel-programming/318469-macro-needed-find-product-cost-another-sheet.html)

Lajos Guta

Macro Needed To Find Product Cost In Another Sheet
 
Newbie to the world of macros and could use some help.

Basically I have on worksheet with Product and Sell Price and another with
Product and Cost. I want to "find" the product cost in the one sheet and add
it to my sell sheet to calculate the profit for each row...

Lajos

Sharad

Macro Needed To Find Product Cost In Another Sheet
 
Helo,

you can use vlookup function.

like
= VLOOKUP(A1,[xyz-workbook.xls]SheetName $A$1:$B1000,colnumber,FALSE)

Where A1 is the product code is sell worksheet.
xyz-workbook.xls is the workbook where product cost is stored.
SheetName is the name of the sheet which actually contains the product
cost.
$A$1:$B1000 is the range where the product number and prodcut costs are
actually stored in the sheet 'SheetName'.
colnumber is an integer refering to the column where the costs is stored
(e.g. if it is column B you replace 'colnumber' with '2')

Sharad

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Sharad

Macro Needed To Find Product Cost In Another Sheet
 
Helo,

you can use vlookup function.

like
= VLOOKUP(A1,[xyz-workbook.xls]SheetName $A$1:$B1000,colnumber,FALSE)

Where A1 is the product code is sell worksheet.
xyz-workbook.xls is the workbook where product cost is stored.
SheetName is the name of the sheet which actually contains the product
cost.
$A$1:$B1000 is the range where the product number and prodcut costs are
actually stored in the sheet 'SheetName'.
colnumber is an integer refering to the column where the costs is stored
(e.g. if it is column B you replace 'colnumber' with '2')

Sharad

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


All times are GMT +1. The time now is 06:00 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com