Charlotte Foust
cfoust at infostatsystems.com
Mon Mar 24 19:12:09 CDT 2008
Rocky, Use the RunCommand approach instead of DoCmd.DoMenuItem. Ver 7 was Access and trying to figure out what the menuitems were is a good way to go nuts! So if the first item is a delete record, it would be: DoCmd.RunCommand acCmdDeleteRecord Heaven knows what acEditMenu item 6 was. Charlotte Foust -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Rocky Smolin at Beach Access Software Sent: Monday, March 24, 2008 4:07 PM To: 'Access Developers discussion and problem solving' Subject: [AccessD] Cancel Produces Error Dear List: The following code for deleting a record, generated by the wiz errors on the second statement if the user clicks cancel to the warning message. DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70 DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70 Is there a right way around this? Placing On Error Resume Next between the statements would probably work but doesn't seem right. MTIA Rocky -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com