1

I have an Excel report where I have to convert money (Column O in the picture) into EUR currency: enter image description here

So far I have been using the IF function, but here the pattern is a bit different. Instead of

=IF(Condition;"true";"false")

I need rather

=IF(P2='EUR';O2);IF(P2='USD';O2*0,78);IF(P2='GBP';O2*1,25);

Just it does not work as it's not a correct Excel expression. Any help ?

4 Answers 4

2

Something like this...

=IF(P2='EUR';O2;IF(P2='USD';O2*0,78;IF(P2='GBP';O2*1,25;NA())))
Sign up to request clarification or add additional context in comments.

Comments

2

You'll have to nest the IF function calls, i.e.

IF(Condition1;Result1;IF(Condition2;Result2;If(Condition3;Result3;SomeDefault)))

Example here:

enter image description here

Comments

2

First arrange a currency values table versus euro for example I did that in sheet 2 on below image

enter image description here

then you can use the formula: =IF(ISNA(VLOOKUP(P2,Sheet2!$A$1:$B$4,2,0)*O2),"Incorrect urrency",VLOOKUP(P2,Sheet2!$A$1:$B$4,2,0)*O2)

2 Comments

This is actually a pretty clever solution. Very relational-database-like. Love it.
Already chosen the right answer, thanks anyway for sharing the tip!
1

Right. I don't have excel, but I did it on Google Spreadsheets, and it works. So what you have to do is to nest the conditions, such as:

=IF(B1="EUR";A1;IF(B1="GBP";A1*1,25;A2*0,78))

So you will get something like:

Sample

Hope this helps!

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.