Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Form/Subform Problem

Status
Not open for further replies.

kalDurak

Technical User
Jun 16, 2004
10
CA
I need a way to display a subform based on the active record in another subform. The setup is as follows

Form A Contains Groups.
SubForm B Contains Members of each group.
SubForm C Contains Details of the selected member.

Any help would be greatly appreciated.
 
How are you displaying the members on subform B? If it's just a continuous form, you can add a button next to each line that will have its 'onclick' event setup so that it updates your subform C.

daniel
 
Thanx for your response, Norwood.

The problem I'm having is that the that I need to bind Subform C to Subform B. Access is telling me that the Subform C is unbound and I can't figure out how to bind it.
 
In order to bind those forms they both need to meet two criteria:

1. They need to have a recordsource, that is, have either a query or table as the source;
2. They need to have a field in common with same data type.

How are your tables setup?

 
I've now attached both to the same query, but the problem is that I need Subform C to display a subset of Subform B. It needs to show the data for whichever record in Subform B is currently selected.
 
Can you upload your DB? It might be easier if I could see what you're doing.

thanks.
 
Sorry, Norwood, but I'd be lucky if I was drawn and quartered if I did that. The client won't even allow a blank version of the db to leave the premesis!

I did solve that portion of the problem. I just did it with two queries:

Subform B:
SELECT DISTINCTROW PolicyTable.ClientNumber,
....
FROM PolicyTable
ORDER BY PolicyTable.PolicySeq
WITH OWNERACCESS OPTION;

Subform C:
SELECT PolicyTable.App_Received,
.......
FROM PolicyTable INNER JOIN DriverTable ON (PolicyTable.ClientNumber = DriverTable.ClientNumber) AND (PolicyTable.PolicySeq = DriverTable.PolicySeq)
WHERE (((DriverTable.ClientNumber)=[Forms]![MAIN]![Client]![CLIENTNUMBER]) AND ((DriverTable.PolicySeq)=[Forms]![MAIN]![Policy Holder]![PolicySeq]))
ORDER BY DriverTable.[Last Name], DriverTable.[First Name]
WITH OWNERACCESS OPTION;

Problem is that I'm now getting a message:
"This Recordset is not updatable"
I'm now chasing that down.
 
I've done a slight redesign of the db. Now the data in subform C is part of the same record that is subform B. Problem is that I need the record in subform C to change whenever I switch the record on subform B. Currently, subform C appears to be independent of Subform B, but changes when I change subform A.

I'm getting a migraine here!
 
Eureaka!

I found what I was looking for in faq702-410. Oddly enough, it was the .jpg file that solved the problem! Sometimes a new perspective is all you need!

Thanks for all your help, norwood and DougP!

I'm sure that I'll be back on Monday with a new set of problems, but that's life!

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top