简体   繁体   English

公式if和vlookup的Excel错误

[英]excel error with formula if and vlookup

=IF(D6=D$62;VLOOKUP(C6;D$63:E$68;2;FALSE);IF(D6=G$62;VLOOKUP(C6;G$63:H$67;2;FALSE))) 

Can some one help? 可以帮忙吗? I have done this formula, but when I press enter then the answer in the cell is false instead of the value which is supposed to look up. 我已经完成了此公式,但是当我按Enter键时,单元格中的答案为false而不是应该查找的值。

This is returning False because the second IF formula doesn't have the third parameter specified. 由于第二个IF公式未指定第三个参数,因此返回False IF takes three parameters, and if you neglect the third, it will just return False . IF接受三个参数,而如果忽略第三个参数,它将仅返回False

What this means is that D6 is not equal to D$62 and D6 is not equal to G$62 , so it says False . 这意味着D6 is not equal to D$62并且D6 is not equal to G$62 ,所以它说False In other words, it doesn't even attempt either Vlookup since neither condition is true. 换句话说,由于两个条件都不成立,因此它甚至都不会尝试Vlookup。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM