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

FindRecord Not Working on Certain Tab?

Status
Not open for further replies.

methodmano

Programmer
Jun 18, 2005
7
US
I have a form that has 2 tabs where on the first tab is the primary key of the information - pSSN. I have another form that is an abbreviated list of information from the first one with primary key pSSN as well. I have a button on the second form that when clicked opens the first form and goes to the complete record of the reference. The code I'm using to do this is:

Private Sub Command_Click()
DoCmd.openForm firstForm
DoCmd.FindRecord Me.pSSN
End Sub

It works fine if the first form is opened to the first tab (the tab containing the pSSN), but doesn't work if the second tab is open. It doesn't give an error, just doens't jump to the record. Is their a way I can switch to the first tab before running the FindRecord command? Thanks!
 
Solved. Sorry about the post.

Forms!firstForm!tabControl.Value = 0
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top