VBA Array Question

What is use of Option Base in VBA.

  Devendra Kumar

Option base is used to set the lower bound 1 or 2 instead of 0 which is default in Array.

When we define any array variable in vba for 10 items then index starts from 0 to 9 but if we want to start from 1 to 10 then we have to write 

Option Base 1 

Before the variable declaration.

  Devendra Singh       12 Jun 2016       0       0     

Post Your Answers:

Please use the CODE HIGHLIGHT Button to format/highlight your codes if any