Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / General 1 / February 2005

Tip: Looking for answers? Try searching our database.

Help

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Igor - 22 Feb 2005 05:46 GMT
Hi,
DoCmd.RunCommand acCmdDeleteRecord
raises error:  2046 The command or action 'DeleteRecord' isn't available
now.
Why could it be?
Thanks
DebbieG - 22 Feb 2005 06:37 GMT
I think it's because you can't delete a blank record.

You might want to just trap this error.

| Hi,
| DoCmd.RunCommand acCmdDeleteRecord
| raises error:  2046 The command or action 'DeleteRecord' isn't available
| now.
| Why could it be?
| Thanks
Igor - 22 Feb 2005 06:48 GMT
from menu it is deleted without any problem

>I think it's because you can't delete a blank record.
>
[quoted text clipped - 6 lines]
> | Why could it be?
> | Thanks
Wayne Morgan - 22 Feb 2005 10:59 GMT
Igor,

Are you running this code in the Click event of a button? If so, is there
any other code in that event? Where is the button located, is it on the form
you are trying to delete the record from?

Signature

Wayne Morgan
MS Access MVP

> Hi,
> DoCmd.RunCommand acCmdDeleteRecord
> raises error:  2046 The command or action 'DeleteRecord' isn't available
> now.
> Why could it be?
> Thanks
Igor - 22 Feb 2005 15:04 GMT
Hi Wayne,
Yes, it is on Click event and button is on the same form

> Igor,
>
[quoted text clipped - 8 lines]
>> Why could it be?
>> Thanks
Wayne Morgan - 22 Feb 2005 15:52 GMT
In that case, unless there is some other code that is interfering, I don't
know. I even checked to see what would happen if you were at a new, unsaved
record. But the code and toolbar button both deleted the new, unsaved
record. No error was generated.

Just to verify, the button is on the SAME form, not a subform or parent form
of the form that has the record you're trying to delete.

Signature

Wayne Morgan
MS Access MVP

> Hi Wayne,
> Yes, it is on Click event and button is on the same form
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.