Search subform?

H

Harmannus

Hallo,

I have a mainform with meeting projectnumbers. On a subform meeting dates
that correspond to the projectnumber. How can i make a search pop-up in
which i state the meeting projectnumber and the meetingdate. The result
showing me the projectnumber and the date.

Thanx in advance for any pointers!


Regards,

Harmannus
 
D

Danny

When you use the Find command on a subform, the search is
confined to the currently active set of subform - Child -
records. E.g., if you're looking at Project Number 100
meeting dates, and there are 3 of them, then the Find
command will only search among those 3 records.

To search the entire set of meeting dates records, you have
to create an independent query that selects from the
ProjectNumber and MeetingDates tables, with an outer join
from the MeetingDates table to the ProjectNumber table. In
this query, display all fields from the parent table, and
as a filter criteria, specify a textbox (to be created) on
your main form.

Create a command button - or a toggle button - on your main
form that sets the recordsource of the form to the query
described above. Create another command button that sets
the recordsource to the original recordsource, so that you
can switch between the entire record set, and the filtered
recordset.

Hope this makes sense. Let me know if you need clarification.

Danny
 
H

Harmannus

Hallo,

Thanx for the tip!

I think i understand. Switching the record source is new to me. A example
mdb would help ;-) Maybe you can email a simple version:
(e-mail address removed)

Thanx in advance for any trouble.

Regards,

Harmannus
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Unbound listbox 4
Multiple Subform Calculation 1
Lebans Calendar Control 4
Order by with sub forms 1
List box behaviour Rli 2
Form/Subform 5
subform duplication records 5
folder and file problem 2

Top