"Copy If" from one workbook to another code?

Nillamasta

New Member
Joined
Oct 8, 2019
Messages
6
Hi all,

I am looking to copy a cells info from one workbook [File1.xlsm] (IF it meets a certain numerical criteria from a diff cell/same row on the same sheet/workbook [File1.xlsm]) to a specific cell in a separate workbook [File2.xlsm].

My digging so far has lead me to this formula (which isn't working...);

=IF([File1.xlsm]SheetX!BE12="173",[File1.xlsm]SheetX!$AX$12,"")

I tried using the above formula in the destination cell of [File2.xlsm] workbook.

Any ideas?

Thank you for your time.
 

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.
Unless you have SheetX, Cell BE12 formatted as text, remove the quotation marks from the 173 and it should work.
 
Upvote 0
Unless you have SheetX, Cell BE12 formatted as text, remove the quotation marks from the 173 and it should work.

perhaps you can/are willing to help me further?


EXAMPLE;
copy info from (cell A1) of [workbookAPI.xlsm]SoldList!
into (cell C1) of [workbook173.xlsm]Sales!
IF criteria from (cell B1) of [workbook173.xlsm]Manifest!
equals manually entered info in (cell D1) of [workbookAPI.xlsm]SoldList!

I'm hoping that translates...

Thank you again for your time!!
 
Upvote 0
Put this in cell C1 of workbook173.xlsm sheet Sales
Code:
=IF([Manifest!B1=[workbookAPI.xlsm]SoldList!D1,[workbookAPI.xlsm]SoldList!A1,"")
 
Upvote 0
Put this in cell C1 of workbook173.xlsm sheet Sales
Code:
=IF([Manifest!B1=[workbookAPI.xlsm]SoldList!D1,[workbookAPI.xlsm]SoldList!A1,"")

That of course worked beautifully. Thank you once again.

I thought I would be able to adapt that idea to automatically;

read the whole column of D (minus the multiple header rows if possible/necassary) in [workbookAPI.xlsm]Soldlist!
identify when info manually entered into a cell in that column (column D in ([workbookAPI.xlsm]Soldlist!)
matches exactly info from a list of unique I.D. numbers in the whole of column B in [workbook173.xlsm]Manifest!
if matching, then copy a cells info located to the left/right (same row) of the "manually entered info cell" in column A of [workbookAPI.xlsm]Soldlist!
then paste the info in the next available blank cell in column C of [workbook173.xlsm]Sales!

Any direction given would be most appreciated.

Gratitude!
 
Upvote 0
Small correction to the above description;

"if matching, then copy a cells info located to the left/right (same row) of the "manually entered info cell" in column D of [workbookAPI.xlsm]Soldlist!"
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,171
Members
453,021
Latest member
Justyna P

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