Using .Requery on a form which got a subform, with another subform in it *headache*

Mirador

New member
Local time
Today, 11:20
Joined
Mar 12, 2004
Messages
9
Hi and thanx for reading my post..

Well.. generally i want to do a :

Forms![frmMAIN]![Subformname].Requery

but the problem is that i got this "frmMAIN" which got "tabsubPerson" as a subform, and in the "tabsubPerson" i got "subqryPersonVehicle" as a subform too.. All this should be done from the "_frmPerson-Vehicle" form.

So... i need to refresh the "subqrypersonVehicle" with the correct syntax of .Requery.

Anyone can help me out with this ?

Best regards
Terje.
 
Mirador said:
Hi and thanx for reading my post..

Well.. generally i want to do a :

Forms![frmMAIN]![Subformname].Requery

but the problem is that i got this "frmMAIN" which got "tabsubPerson" as a subform, and in the "tabsubPerson" i got "subqryPersonVehicle" as a subform too.. All this should be done from the "_frmPerson-Vehicle" form.

So... i need to refresh the "subqrypersonVehicle" with the correct syntax of .Requery.

Anyone can help me out with this ?

Best regards
Terje.

try:

Forms![_frmPerson-Vehicle]! [tabsubPerson].form![subqryPersonVehicle].Requery

hth.
 
Found the form/sub/sub but didn't requery.

Thanx for your reply :)

Well.. it went through, but didn't .requery :)
Tried running the .Refresh after this, but that object wasn't supported for the method (??)...

Anyway.. it seems i miiight need to create something more "global", because this database is kind of a "datadump" for all criminal investigation and there are soo many many-to-many and connection-tables.

I'm using "Category-control" in the "tabsubPerson" subform, with a "sheet" for each relation from the current form to the others.. Like "Person-Vehichle", "Person-Crimescene", Person-Telephone" etc.etc.etc..

So therefore i might need to run a .Requery on all the "sheets/tabs". Not sure how i can do that without seriously affecting the speed of loading the forms.

If anyone got any good ideas, it's most apprectiated..

*/Terje*/
 
Never refer to an object on the current form or subform with the external reference style. Use Me. so you can take advantage of intellisense and early binding. So to requery a subform - Me.SubformName.Requery - that should also force the sub-subform to requery as long as the master/child links are properly set.

Why do you need to requery the subform anyway?

Why does your subform name start with an underscore?
 

Users who are viewing this thread

Back
Top Bottom