P
piet
I have created a continues form, based on a query. In the header, there are
some comboboxes that gives the user the possibility to make certain
selections. Everytime a selection is made on a combobox, there is a VBA
action: ME.REQUERY. That works very fine: the user sees always the result of
his selection(s). There is also a textbox in the header that shows the
number of records in the form (Therefore I use DCOUNT).
Now I've got two problems, when the query returns no records (because the
user choose a selection of items that aren't in the database):
1. The textbox is not updated (should show 0 records).
2. The combobox where the last selection has been made, becomes empty????
I thought I could interfere with some code after the requery, but that don't
works. Is there any idea how to check if the underlying query returns no
records and do some action before updating the form? I can by example show a
message to the user: "there are no records that match your criteria".
Txs
Piet
some comboboxes that gives the user the possibility to make certain
selections. Everytime a selection is made on a combobox, there is a VBA
action: ME.REQUERY. That works very fine: the user sees always the result of
his selection(s). There is also a textbox in the header that shows the
number of records in the form (Therefore I use DCOUNT).
Now I've got two problems, when the query returns no records (because the
user choose a selection of items that aren't in the database):
1. The textbox is not updated (should show 0 records).
2. The combobox where the last selection has been made, becomes empty????
I thought I could interfere with some code after the requery, but that don't
works. Is there any idea how to check if the underlying query returns no
records and do some action before updating the form? I can by example show a
message to the user: "there are no records that match your criteria".
Txs
Piet