I didn't quite understand your example in that I saw that you incremented recNo and then returned it. At first look I was under the impression that it was returned right after it was incremented and that the rest of the function was not being executed. Having looked at it again, I think I now see what is actually happening. The recNo is incremented and after executing the rest of the function using the new value of recNo, then it is reutrned to update the global. I went back and changed my code to yours and it is working fine.
Thank you. I really do appreciate you help and your patience.
Thank you. I really do appreciate you help and your patience.