我试图寻找与错误424的问题,但我没有找到任何符合我的情况。VBA错误424与空
我正在3号线一个424错误:
For icount = 2 To no_items
If hid.Cells(icount, 1).Value > 0 Then
'If hid.Cells(icount, 1).Offset(-1).Value Is Empty Then
'hid.Cells(icount, 1).Value = 1
'Else
hid.Cells(icount, 1).Value = 1 + hid.Cells(icount, 1).Value
'End If
End If
Next
我的声明如下:
Dim hid As Worksheet
Set hid = ThisWorkbook.Worksheets("Hidden")
hid.Visible = True
之前,我曾与第2行相同的错误:
If hid.Cells(icount, 1) is not empty Then
我不明白为什么会出现错误,一切都按照它应该的方式定义。 你能帮我吗?用于不为IsEmpty
见下文 –