My query (qryVal) output looks like this, sorted by Val1 then Val2:
Val1 Val2
1 4
1 9
1 13
...
1 42
2 5
2 9
etc...
In code module, I call function Process(Val1). Inside this function is a loop that needs to cycle through each value of Val2. For example, if I call Process(1) , the loop needs to run through values of Val2 = 4, 9, 13,.... 42.
How do I set up this loop? I'm having trouble with the syntax.
Thanks in advance.