Friends

24sharon

Registered User.
Local time
Today, 11:18
Joined
Oct 5, 2004
Messages
147
Hello,

I have a form with subform,

I want to open the form where the value of the fatherForm is X and the value of the subform is Y.

How can I do it?

Thanks
 
Open the main form with a filter or OpenArgs, and the sub-form will be linked [presumably] to the first record related to the record in your main form.

HTH :)
 
Sorry...

I didnt understood how to do it, then I attach file if some one can explain me how do I do it?

THANKS ALOT
 

Attachments

I can't download your sample due to my site's security restrictions. So I'll have to address the theoretical side of your question.

Normally, a parent/child form situation has a common field shared between the tables/queries that drive the individual forms. Usually, the fields shared between the parent and child TABLES underlying the forms (directly or through a query) have a relationship defined between them.

When you say the parent is on record X and the child is on record Y, you are implying that the normal linkages do not apply. Unless this is because you are doing a search from the parent and showing results in the child, I cannot imagine a value for this case. HOWEVER, if this is a search situation, look up "cascading combo boxes" as a topic on how to make a form search records to find records based on arbitrary criteria.

The techie way to do this is that you must update the recordsource of the child form, which is usually a named query. In this case, you have to "roll your own" query. Which is generally considered an advanced function. If you redefine the recordsource query, you would have to force the child form to requery its own recordsource. In such cases, the child form is unbound with respect to the parent form (even though it is bound to a recordsource of its own).
 

Users who are viewing this thread

Back
Top Bottom