Unbound Forms - Switchboard problem

G

Guest

Have a number of unbound forms. The following code works fine on one, but
when cmdClose_Click on one of the others - nothing happens - perplexed !? I
cut and pasted the code too !?

Private Sub cmdClose_Click()
DoCmd.Close
Forms.Item("MainSwitchBoard").Visible = True
End Sub

In both cases cmdButton to open form on the Switchboard is "
Forms.Item("MainSwitchBoard").Visible = False"

As always - any help - much appreciated !!! Ian
 
G

Guest

Hi,
try to reference the whole syntax instead e.g.:

Forms!MainSwitchBoard.Visible = True
DoCmd.Close acForm, Me.Name

HTH
Good luck
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top