如图所示,在H2中输入什么公式,可以查出“始发地是北京”,“到达地是河北”的,对应的等级“低”呢?
'自定义公式-按ALT+F11-插入-模块-粘贴代码Function 双条件求值(a As Range, b As String, c As String)For i = 1 To a.Rows.CountIf a.Cells(i, 1) = "" Then Exit ForIf a.Cells(i, 1) = b And a.Cells(i, 2) = c Then 双条件求值 = a.Cells(i, 3)NextEnd Function