How do I make the form visible again?

Steven811

Registered User.
Local time
Today, 19:42
Joined
Apr 18, 2004
Messages
133
I am creating a set of cmd buttons on a parent form for navigation around that and the 4 nested sub forms. When I move the focus to one of the sub forms and use the button the parent form becomes invisible.

How do I change this so that it remains visible at all times?

Here is the code for one of the buttons

Private Sub cmdPrevious_Click()

On Error GoTo cmdPrevious_Click_Err

Screen.PreviousControl.SetFocus
DoCmd.GoToRecord , "", acPrevious

cmdPrevious_Click_Exit:
Exit Sub

cmdPrevious_Click_Err:
MsgBox Error$
Resume cmdPrevious_Click_Exit

End Sub

I've tried

Private Sub Form_LostFocus()
MyForm.Visible = True
End Sub

But it still doesn't work.

Any assistance would be appreciated.

Thanks
 
hi,
I had the same problem in one of my forms, but when I allowed add record in the properties, the form was showing. Try enabling allow additions in the form's properties.

Hope that helps
 
Very odd

Hi Charles

That was already enabled.

Thanks anyway

Steven811
 
It sounds like a field linking problem to me. Have you checked your subforms for errors in the "Link Fields" properties?
 

Users who are viewing this thread

Back
Top Bottom