有人可以解释为什么这个数组公式不起作用?谢谢!
Dim myArray As Variant
Dim yourArray As Variant
myArray = Sheets("db_main").Range("S2:S200").Value
yourArray = Sheets("export").Range("A2:A200").Value
If myArray < 4000 Then
yourArray.Value = myArray.Value
End If
答案 0 :(得分:1)
您需要遍历每个单元格。
For Each c In Worksheets("db_main").Range("S2:S200").Cells
If c.Value < 4000 Then Worksheets("export").Range("A" & c.Row) = c.Value
Next