how to check if number begins with “+” in excel?

左心房为你撑大大i 提交于 2020-05-17 08:49:29

问题


I need to check if a number begins with "+" or "00" or "(" but when I try with this formule:

=IF(LEFT(E4="+",1),1,0)

I get an error #VALUE


回答1:


Try to include OR logic including a wildcard in a COUNTIF and use that in an IF:

=IF(SUM(COUNTIF(E2,{"+*","(*","00*"})),"This","That")

If you got leading spaces in front of the + then just add a space before the criteria. I guess you could also add another criteria like " +*. Unfortunately TRIM() won't work within a COUNTIF.



来源:https://stackoverflow.com/questions/61821277/how-to-check-if-number-begins-with-in-excel

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!