By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,397 Members | 1,467 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,397 IT Pros & Developers. It's quick & easy.

Delete button is not working

P: n/a
Windows 2000
Access 2000

I have the standard Delete button code. This has been working for over
3-4 years and now it gives me an error message of 2465 everytime I
delete a record.

Here is the delete code I use.
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70
-Niranjan
Nov 13 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Niranjan wrote:
Windows 2000
Access 2000

I have the standard Delete button code. This has been working for over
3-4 years and now it gives me an error message of 2465 everytime I
delete a record.

Here is the delete code I use.
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70
-Niranjan


In your error routine, change from
Msgbox Err
to
msgbox err.Number & " " & err.Description

It is so much easier to help people when they supply information that
describes a problem. BTW, what's an error 440, off the top of your head.

Nov 13 '05 #2

P: n/a
The two DoMenuItem commands are a programmatic way of choosing Select Record
followed by Delete from the menu bar.
These were replaced by a single command way back in Access 97:

DoCmd.RunCommand acCmdDeleteRecord

But it seems the code wizard has not been updated.

"Niranjan" <nh****@hotmail.com> wrote in message
news:19*************************@posting.google.co m...
Windows 2000
Access 2000

I have the standard Delete button code. This has been working for over
3-4 years and now it gives me an error message of 2465 everytime I
delete a record.

Here is the delete code I use.
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70
-Niranjan

Nov 13 '05 #3

P: n/a
Ian:
Thanks for your response. But that did not answer my question. If
anyone has any ideas, I really would appreciate it.
-Niranjan
"Ian Hinson" <pp******@bigpond.net.au> wrote in message news:<%w*****************@news-server.bigpond.net.au>...
The two DoMenuItem commands are a programmatic way of choosing Select Record
followed by Delete from the menu bar.
These were replaced by a single command way back in Access 97:

DoCmd.RunCommand acCmdDeleteRecord

But it seems the code wizard has not been updated.

"Niranjan" <nh****@hotmail.com> wrote in message
news:19*************************@posting.google.co m...
Windows 2000
Access 2000

I have the standard Delete button code. This has been working for over
3-4 years and now it gives me an error message of 2465 everytime I
delete a record.

Here is the delete code I use.
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70
-Niranjan

Nov 13 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.