Peter,
>In addition: Reccount() can be calculated prior to doing the select-sql and put into a variable that is used in, or passed to, the progressbar function. Furthermore, another variable can be used for the current recno, becasue we know (we have set) the interval for the function call. So, simply increase that (probably also passed on) variable in the function. In this scenario we do not even have a need for reccount() and recno().
The idea of using a separate variable sounds like the perfect (and safest) solution. I'm thinking that I could be build a simple, light weight wrapper class for my SQL statements that require a progressbar and use either a property of the class or a temporary private variable as my counter.
Malcolm