将2个IF语句合并为一个

时间:2018-10-27 15:49:34

标签: excel if-statement

我在2个单独的单元中具有这2条IF语句,并希望使它们在一个单元中起作用。我尝试了几种合并方法,但无法使其起作用。 IF声明专家可以帮助我将这两个结合吗?

1 st。

=IF(K21<0.01,("DTI Ratio Available "&TEXT(K21*-1,"$ 0.00")),("DTI Ratio Short by  "&TEXT(K21,"$ 0.00")))

第二。

=IF(K20<0.01,"Housing Ratio Available "&TEXT(K20*-1,"$ 0.00"),"Housing Ratio Short by "&TEXT(K20,"$ 0.00"))

非常感谢您

1 个答案:

答案 0 :(得分:0)

尝试一下:

=CONCATENATE(
    IF(K21<0.01,("DTI Ratio Available "&TEXT(K21*-1,"$ 0.00")),("DTI Ratio Short by "&TEXT(K21,"$ 0.00"))),
    " ",
    IF(K20<0.01,"Housing Ratio Available "&TEXT(K20*-1,"$ 0.00"),"Housing Ratio Short by "&TEXT(K20,"$ 0.00"))
            )