Hi everybody!
I have a form (form1) with a listbox (lstSelectContacts).
This listbox is based on table1.
To fill this listbox, form1 calls another form (form2) which is a special form for filtering.
After filtering, form2 fills table1 and calls back form1.
The listbox in form1 now shows the items filtered and stored in table1.
In form1 I have a textbox called "qty" to show the number of items in listbox.
I'm using the following code in listbox.after_update:
qty = Me!lstSelectContacts.ItemsSelected.Count
Well, when form1 is opened again from form2, "qty = 0" (it doesn't sow the number of items)
But when I click the listbox, PRESTO! "qty" shows the real number of items!
I would like that when form1 is opened "qty = n" (where "n" is the number of items in listbox) without the action of clicking the listbox.
Am I supposed to try another event?
Thanks a lot
pozzo
I have a form (form1) with a listbox (lstSelectContacts).
This listbox is based on table1.
To fill this listbox, form1 calls another form (form2) which is a special form for filtering.
After filtering, form2 fills table1 and calls back form1.
The listbox in form1 now shows the items filtered and stored in table1.
In form1 I have a textbox called "qty" to show the number of items in listbox.
I'm using the following code in listbox.after_update:
qty = Me!lstSelectContacts.ItemsSelected.Count
Well, when form1 is opened again from form2, "qty = 0" (it doesn't sow the number of items)
But when I click the listbox, PRESTO! "qty" shows the real number of items!
I would like that when form1 is opened "qty = n" (where "n" is the number of items in listbox) without the action of clicking the listbox.
Am I supposed to try another event?
Thanks a lot
pozzo