我想找到一种方法,自动填充从一列到另一列,一旦数字在BB列,取决于BB列的数字,这就是我想在代码中找到的逻辑。如果列BB大于0或等于19,则列BD将沿列向下写“黑”。如果BB列大于20或等于99,则BD列将沿列向下写“灰色”。如果BB列大于100或等于199,则BD列将沿列向下写“白色”。我没能想出一个解决办法。
2ul0zpep1#
像这样?:=SWITCH(TRUE,AND(B1>=0,B1<=19),"Black",AND(B1>=20,B1<=99),"Grey",AND(B1>=100,B1<=199),"White","OUT OF RANGE")
=SWITCH(TRUE,AND(B1>=0,B1<=19),"Black",AND(B1>=20,B1<=99),"Grey",AND(B1>=100,B1<=199),"White","OUT OF RANGE")
1条答案
按热度按时间2ul0zpep1#
像这样?:
=SWITCH(TRUE,AND(B1>=0,B1<=19),"Black",AND(B1>=20,B1<=99),"Grey",AND(B1>=100,B1<=199),"White","OUT OF RANGE")