Solved

Buttons fail on ACCDE

Posted on 2012-04-02
8
694 Views
Last Modified: 2012-04-02
Windows 7 32, Access 2007

I have an Access 2007 ACCDB that works fine.  The Trust Center settings in Access cover both the folder where the backend is (server) and where the front end is (local PC).  I create an ACCDE since I don't want users putzing with the application. Right now it is in the same folder as the ACCDB.

None of the buttons on the switchboard form work when I run the ACCDE.  Tabs work. Just the buttons fail.  I get no messages.  The button 'depresses' to show it was clicked but no new form opens.    

I have just discovered something.  If I open the ACCDE with the shift key held and I then do Alt-F11 to get into VBA there is no code available.

What am I missing?
0
Comment
Question by:IBMJunkman
  • 4
  • 3
8 Comments
 
LVL 47

Expert Comment

by:Dale Fye (Access MVP)
ID: 37797152
The reason the code is not available is because it is an ACCDE

Cannot say that I've run into a similar problem where code in an accde installed in a folder which is a trusted location will not run.
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 37797272
Is this an issue just with the switchboard buttons...?

...In other words, ...Will buttons on other forms work?

Before you created the accde file, did you compile your code and compact/repair the DB...?
0
 

Author Comment

by:IBMJunkman
ID: 37797372
How to I compile the code?  I thought creating the ACCDE did that?

I opened a couple of other forms and their buttons don't work either.
0
Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

 

Author Comment

by:IBMJunkman
ID: 37797399
I just tried the ACCDE on Windows 7 64 Access 2010.  Still does not work.

Then I created the ACCDE with Access 2010.  Still does not work in Access 2010.  And understandably Access 2007 complains about the DB format.
0
 
LVL 74

Accepted Solution

by:
Jeffrey Coachman earned 250 total points
ID: 37797485
<How to I compile the code?  I thought creating the ACCDE did that?>
Yeah, but why wait until you create the Accde file to find out if there are any errors?
;-)

In the VBE click : Debug-->Compile...

<Then I created the ACCDE with Access 2010.  Still does not work in Access 2010.  And understandably Access 2007 complains about the DB format.>
Let's be clear...
What "Format" is the DB in...

I thought you stated that this was an Access 2007 format DB...?
If so then you should create the accde file in Access 2007.
...just to see if it works...

In other words, *Before* you ever opened the DB in Access 2010, ...could you create an accde file form this accdb in Access 2007?


You also did not state if (or when) you were running the C&R utility...

Here is the sequence I would use, just to be sure...

Access 2003 running an Access 2003 format DB (.mdb):
Compile code-->Compact repair-->Create MDE file
Does MDE file work?
If, No, then stop and fix.
If yes, then continue....
Create new blank Access 2007 format DB (.accdb) in Access 2007
Import all objects from the mdb file into the new accdb file
Compact and Repair-->Compile code--> Compact and repair again-->Create accde file
Does accde file work?
If, No, then stop and fix.
If yes, then continue....
Create new blank Access 2010 format DB in Access 2010
Import all objects from the access 2007 format DB into the new Access 2010 format file
Compact and Repair-->Compile code--> Compact and repair again-->Create accde file
Does accde file work?
0
 

Author Comment

by:IBMJunkman
ID: 37797725
In Access 2007 I just compiled the VB code.  Exited Access.  Opened the ACCDB and created the ACCDE. Closed Access and opened the ACCDE.  Now the buttons work.

I don't want a 2010 version.  The users have 2007.  The version I made my changes to was already 2007.  I was just playing around with 2010 trying to see what was wrong.
0
 

Author Closing Comment

by:IBMJunkman
ID: 37797734
Compiling the VB code seemed to fix the problem.
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 37799054
Just note that "Playing" around with a 2007 format db in Access 2010 (and saving the changes) will sometimes cause the Access 2007 users to get the "Unrecognized format" error when trying to open the db, so be careful not to do anything "2010 specific" (navigation forms, ...et al)
see here for more info:
http://social.msdn.microsoft.com/Forums/en-US/accessdev/thread/99e2eedf-0a36-4d38-9713-f3c82018c804
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction The Visual Basic for Applications (VBA) language is at the heart of every application that you write. It is your key to taking Access beyond the world of wizards into a world where anything is possible. This article introduces you to…
It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
What’s inside an Access Desktop Database. Will look at the basic interface, Navigation Pane (Database Container), Tables, Queries, Forms, Report, Macro’s, and VBA code.
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question