Buttons in a Pop up form don't work

G

Guest

I have a continuous form with records that is a pop up form. I have delet
record buttons for each record in this form, but they don't work when the
form is set to pop up. When the form is not a opo up the buttons work fine.
Any suggestions to fix this with code???
 
M

missinglinq via AccessMonster.com

There being no reason for this to be so, it sounds like some sort of
corruption to me. Was the delete button generated by the Comand Button Wizard?
At any rate, I'd try the old make a blank database and import the objects (at
least those you need to run the form) and try it again!
I have a continuous form with records that is a pop up form. I have delet
record buttons for each record in this form, but they don't work when the
form is set to pop up. When the form is not a opo up the buttons work fine.
Any suggestions to fix this with code???

--
There's ALWAYS more than one way to skin a cat!

Answers/posts based on Access 2000

Message posted via AccessMonster.com
 
A

Allen Browne

You may need to tell use more about the code in those buttons.

If you used the wizard to create the code, it probably uses DoMenuItem. But
the menus are not available in the popup, so the buttons don't work either.

Try something like this:

Private Sub cmdDelete_Click()
If Me.Dirty Then Me.Undo
If Not Me.NewRecord Then
RunCommand acCmdDeleteRecord
End If
End Sub
 

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

Top