如果能够既可用特殊符号,又能用数字符号表示就更好啦,如:☆☆☆表示有这样的数三个!我先在这谢谢啦!请高手不吝赐教!
教你一个方法:
先ALT+F11,进入VB界面,对着左边的工程资源管理器中workbook——右键——插入——模块
粘贴如下代码:
Function geshu(ByVal rng As Range, ByVal small As Double, ByVal large As Double, ByVal fuhao As String)
Dim s As String
s = ""
For Each a In rng
If a.Value >= small And a.Value <= large Then
s = s & fuhao
End If
Next a
geshu = s
End Function
然后再回到EXCEL界面:输入如下公式:=geshu(A1:D1,1,5,"*")
"*"双引号里面的内容自己定义,1和5是最大数和最小数,A1:D1是你想要计算的区域