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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Requery Subform

Status
Not open for further replies.

rsheaffer

Technical User
Nov 9, 2000
4
US
I have been trying to requery a subform on the main form and nothing has worked yet. It used to work in Access 97 (and now does not in 2000) with a simple requery in the "On Enter" and "On Exit" modules. Can someone please help me with this! I have tried numerous things.

Subform: frmHardDriveLinkSubform
Main Form: frmPCMain

Thank you!
 
Set the Procedure for On Got Focus to:

Me.Requery

and On Lost Focus to:

Me.frmHardDriveLinkSubform.Requery

This should work...

This has to be set using VBA
Sub frmHardDriveLinkSubform_GotFocus()
Me.Requery
End Sub
and
Sub frmHardDriveLinkSubform_LostFocus()
Me.frmHardDriveLinkSubform.Requery
End Sub

as there isn't an On Got Focus Event in the properties of a subform/subreport. Email me if you are having difficulties. jo.dennis@acxiom.com

Otherwise, you could change the On Lost Focus event of the previous field in the tab order to:

Me.frmHardDriveLinkSubform.Requery

Hope this works. I have been trying to test it on a package of mine, but am having troubles with my PC.

Jo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top