sub5
Programmer
- Oct 12, 2005
- 104
Hi all,
I get error 3021 no current record when I open a form which has listbox whose row source property is refering to to a user defined function which moves through the records in a query to populate the list box.
There is nothing in the listbox row source.
The function is a private function in the form's module.
I know there is no current record because I need to create some before I get to the list box. I am not querying the list box in any procedures relating to opening the form.
Why does it jump to my user defined function on form open?
What do I do to stop it running that procedure until I want it too ie until I have created the data? (I have tried disabling the listbox until I want it but that failed)
I get error 3021 no current record when I open a form which has listbox whose row source property is refering to to a user defined function which moves through the records in a query to populate the list box.
There is nothing in the listbox row source.
The function is a private function in the form's module.
I know there is no current record because I need to create some before I get to the list box. I am not querying the list box in any procedures relating to opening the form.
Why does it jump to my user defined function on form open?
What do I do to stop it running that procedure until I want it too ie until I have created the data? (I have tried disabling the listbox until I want it but that failed)