Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

array array

Status
Not open for further replies.

cjkenworthy

Programmer
Sep 13, 2002
237
GB
I have two dynamically sized arrays with values in:

array1 and array2

previously with only one array I could do:

for I=0 to Ubound(array1)
'Do some SQL using each value in array1
next

BUT now I have two arrays and I want to do a similar thing i.e. for each value in both arrays do some SQL. Something like:

for I=0 to Ubound(array1) and Ubound(array2)
'Do some SQL using each value in array1 and array2
next

This is not proper VBscript of course, so how would i do this? The arrays have an identical number of values:

value1 in array1 corresponds to value1 in array2 etc..

How do I do this without doing a nested 'for' loop which is not what i want.

Thanks for your help,

Chris
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top