高手帮看下怎么编合适
有5个label ,分别是label1 ,label5 ,label9 ,label13 ,label17。我想给它们赋值。于是用了如下语句:m1 = -3 ' 用来写入5个序号
For m = 1 To 2700
If xlSheet.cells(m, 1) = 1 Then
xlSheet.cells(m, 1) = ""
m1 = m1 + 4
Label(m1).Caption = xlSheet.cells(m, 2) '运行出错行!!!!!
End If
If m1 = 17 Then Exit For
If m = 2700 Then
Label21.Caption = "全部错题已经订正完"
Exit For
End If
Next
运行时出错,看来这样写label(m1)来分别代表这5个label是不行的,怎么办好呢?