Problem selecting records in subform

G

Guest

I have an unbound form with a subform that is populated by selecting from a
combo box on the main form. The value of the combo box is linked to the
subform via Master/Child fields.

This works ok except to display the correct records, but when I try to
select any record in the subform other than the first record, the main form
displays "Calculating.." in the status bar and it then jumps back up to the
first record in the subform. No event procedures have been coded on the main
form or the subform and the child/master fields are not calculated fields.

Any ideas what could be causing this behavior?

Thanks much for your help!
Bonnie
 
A

Al Borges

Hi Bonnie:
from a combo box on the main form. The value of the combo box is linked to
the subform via Master/Child fields.

I don't understand how in the world you could link Master/Child forms if the
Master is unbound? Possibly it can be done, but I've never gone that route.
I either have:

1) bound Master/Child forms that "pull" the information
2) an unbound form with a combobox that "pushes" information onto various
unbound fields

I guess one way to do what you want more efficiently would be to manually
reset the form's recordsource directly by placing the following in the
Parent form combobox's AfterUpdate event:

Forms![ParentForm]![ChildForm].form.recordsource =
Forms![Parent].RecordSource = "SELECT TableStuff.* FROM TableStuff Where
TableStuff.Account = Forms![Parent]![Combobox].value; "

That should get rid of the calculating...

Regards,
Al
 
G

Guest

Thanks Al,

You can find reference to using an unbound form with a combo box that
populates a subform at the following MS KB article:

http://support.microsoft.com/default.aspx?scid=kb;en-us;209537

Method # 3 in the article is the way I have it set up.

Thanks for your help, I am going to try your suggestion. I suspect something
with the underlying query that is the subform's recordsource, so your
suggestion may take care of it.

Thanks!
Bonnie
 

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

Top