how do you write a function that would read a query, count the number of rows of the query result and then print it on to a list box? i have a list box on my form and i'm trying it get it to read a query and list only the number of rows of the resulting query. thank you for your help. this forum is great!!!