Greetings. I am a beginner. I have a problem: Based on the content of a cell, the value should be picked from one of the two cells. For example, if F3= “MMC” then value should be picked from I3 OR K3. How to do it without macro?. Thanks in advance.
See the IF() function.
=IF(F3="MMC";IF(ISBLANK(I3);K3;I3))
If F3 equals the text MMC
then if I3 is blank return K3, else I3.
Thanks for the response.
When I typed this
=IF(E14=“MMC” ,F14 ,I14)
the resulting value is picked up from F14 if there is a value and if there is no value in F14 it returns 0 even when there is a value in I14. Moreover, when I used semi colon as you have given, it changes to comma! Where did I go wrong?
You didn’t say what exactly you want.
You said “if F3= “MMC” then value should be picked from I3 OR K3”, so how is that to be understood then?
The semicolon after input is automatically changed to the function parameter separator your locale uses, there’s nothing wrong with that
Thank you for taking so much trouble to reply. I appreciate it. May be I am not clear. So let me rephrase the issue. If F3=“MMC”, then value should be picked up from I3 OR K3. And some value will be there in one of these two cells and not in both. So when I inserted the solution given by you, it successfully picks up value from the first cell (if there is a value in that cell) but if there is no value in the first cell, it does not pick up the value in the second cell even when there is one. It simply returns 0. Hope I am clear now. Thanks
See updated answer.
You didn’t say what should happen if F3 is not MMC
; as is, the expression returns 0 or FALSE.
Thanks. So if F3 is not MMC, it should return 0.
=IF(F3="MMC";I3&K3)
That returns a text string though, but the OP also didn’t say whether the values in I3 or K3 would be numeric or text nor if the result should be numerically calculated with (which text wouldn’t suit).
Hi, The values in I3 or K3 are numeric and there is no further calculation.
=IF(F3=“MMC”;I3+K3;0)
As I said earlier, the value will be either I3 OR K3 but not adding both . But yes, it picks up the value from one of the cells. Does work though. Thanks