View Single Post
 
Old 04-03-2020, 02:21 PM
MK3 MK3 is offline Windows 10 Office 2019
Novice
 
Join Date: Apr 2020
Posts: 1
MK3 is on a distinguished road
Cool Insert value if not existing

Hi community
I am new and this is my first post.

From column A6 onwards (ends at A25), I have listed some currencies.

Column H2 until H4 has listed the 3 most common currencies that I need and the related exchange rate to each currency, which are always 2 different exchange rates per currency. This would be the matrix H2:J4

If I list a new currency in column A9 (for example GBP), which is not available in the matrix H2:J4, I would want that this currency to be inserted in E2.
Another currency that would not be listed then in E3, and another (last one) in E4.

I tried with the following but it does not write the currency in the cell. It shows a #NA in the cell.
=if(A6=vlookup(A6;H2:H4;1;0);"";A6)
This would not work anyway as it needs some kind of loop to check it withing the range of A6:A25)

Can anyone help? Do I need wo write here a VBA code or is that possible with formulas?

Attached is a file in oder to make it clearer.

Thank you and cheers.
Attached Files
File Type: xlsx Excel Insert if not available.xlsx (11.8 KB, 10 views)
Reply With Quote