RobbieC
Active Member
- Joined
- Dec 14, 2016
- Messages
- 376
- Office Version
- 2010
- Platform
- Windows
Hi there, I want to run a 'For each loop' on an array.
I have the following code which will do what I need for a continuous string of numbers:
but in this new case I only want several numbers : 1, 4, 9, 10, 15, 17, 23 etc
is it possible to run my above code with something like:
If you can point me in the right direction, I'd be very grateful.
Thanks
I have the following code which will do what I need for a continuous string of numbers:
Code:
For i = 1 to 26
'do something with i
next
but in this new case I only want several numbers : 1, 4, 9, 10, 15, 17, 23 etc
is it possible to run my above code with something like:
Code:
For i = array(1, 4, 9, 10, 15, 17, 23)
'do something with i
next
If you can point me in the right direction, I'd be very grateful.
Thanks