Brad Marks
BradM at blackforestltd.com
Thu Apr 11 13:36:42 CDT 2013
Rocky, Thanks for the assistance. I followed the steps that you suggested. When I Right Click on one of the buttons, select "Build Event", then select "Code Builder" the VBA Window is opened. The catch is that normally it would open up to something like this ... Private Sub Command99_Click() End Sub However, when the VBA Window is opened, it shows Option Compare Database Option Explicit Which is at the top of the heap. I added a brand new button and things worked nicely. It appears that I have a very messed up report. I deleted the Report and then copied it in from a backup copy of the accdb file. This fixed the problem with the buttons. I am still puzzled about this problem because I have not worked with this report for many weeks. I guess that I may have angered the "Access Report gods" :-) Thanks again for your ideas and insights. Brad -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Rocky Smolin Sent: Thursday, April 11, 2013 8:37 AM To: 'Access Developers discussion and problem solving' Subject: Re: [AccessD] Access 2007 Report - Buttons Quit Working Brad: After you copy the event code (excluding the Private Sub and End Sub lines) delete the event code (including the Private Sub and End Sub lines) you will need to recreate it. Display the property sheet for the button (right click button, select Properties)-->Events Tab-->On Click Event-->Drop down combo box and select [Event Procedure]--->click builder button to the right (button with the three dots). Then it will flip to the VBA page and you'll see the Private Sub and End Sub lines. Paste your copied code in there. HTH Rocky -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Brad Marks Sent: Thursday, April 11, 2013 5:32 AM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Access 2007 Report - Buttons Quit Working Rocky, I tried the steps that you suggested (copy out the code, delete the module, and recreate it, pasting back the code). When I try to recreate the code, the VBA editor is opened, but it is not showing the buttons Click event but it is showing code for another button. I am not sure how things work behind the scenes, but it appears that the "links" between the buttons on the report and the VBA code are messed up. Thanks for your help. Brad -----Original Message----- From: accessd-bounces at databaseadvisors.com on behalf of Rocky Smolin Sent: Wed 4/10/2013 7:33 PM To: 'Access Developers discussion and problem solving' Subject: Re: [AccessD] Access 2007 Report - Buttons Quit Working How about if you copy out the code, delete the module, and recreate it, pasting back the code? Rocky -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- This message was scanned by ESVA and is believed to be clean. Click here to report this message as spam. http://h0stname/cgi-bin/learn-msg.cgi?id=B440E289AF.DB614