VBA - how to conditionally skip a for loop iteration

后端 未结 6 1246
Happy的楠姐
Happy的楠姐 2020-11-30 01:23

I have a for loop over an array. What I want to do is test for a certain condition in the loop and skip to the next iteration if true:

For i = LBound(Schedul         


        
6条回答
  •  夕颜
    夕颜 (楼主)
    2020-11-30 02:06

    Continue For isn't valid in VBA or VB6.

    From this MSDN page it looks to have been introduced into VB.Net in VS 2005./Net 2.

    As the others have said there's not really an option other than to use Goto or an Else.

提交回复
热议问题