My ACCDE app will not execute any code from the Module or form's "code behind". Why?

I have added my ACCDEs location to the Trust Center but still am not able to get the ACCDE to execute any code that is located in any of the the app's modules.

What else could be wrong?
LVL 1
BruceAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
What version of Access was used to create the ACCDE?  Did you Debug, Compile first? What version are is it running in?
0
BruceAuthor Commented:
2013.  I have forced a "compile" as well before saving as ACCDE
0
crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
are any of the tables linked? Are those locations trusted as well?

> "forced a "compile" "

what do you mean by this?  Best to Debug, Compile, then Save, then create the ACCDE

perhaps something was wrong with the code ...

are you running in the same version that was used to compile?  what version(s) is being used?
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Protecting & Securing Your Critical Data

Considering 93 percent of companies file for bankruptcy within 12 months of a disaster that blocked access to their data for 10 days or more, planning for the worst is just smart business. Learn how Acronis Backup integrates security at every stage

BruceAuthor Commented:
Tables are internal.

"forced a 'compile'"...   From the "Debug" menu in the VBA editor I selected "Compile..."
0
crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
if all compiles ok, then SAVE before creating the ACCDE
0
crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
also, perhaps you are referencing libraries that the user does not have ... hence my question about versions?
0
crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
Go to Tools, References, and post a screenshot of the libraries that the database needs.  Thanks
0
aikimarkCommented:
Open the database with the /decompile command line option.  Then do your compile.
0
crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
decompile is a good idea.

'~~~~~~~~~ Decompile ~~~~~~~~~

if you have odd behavior, backup your database and then decompile it

make an make a "generic" decompile icon where the next database you open will be decompiled... use this as the target:

"C:\Program Files\Microsoft Office\Office\MSACCESS.EXE" /decompile

if your Access program is not located in the directory specified, make the appropriate substitution

the next database you open will be decompiled... you can verify this by going to the design view of any module -- Compile will not be gray, it will be available

then, compile the database
then, do compact/repair
0
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
Never, ever do a Decompile without first making a copy of your DB  (Control C, Control V in Windows Explorer). Whereas it's extremely rare, Decompile can (and has) completely trash your db.
0
crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
absolutely, Joe is right!  ... thanks for jumping in

Backup your database before decompile ... mark the backup as having been done right before the decompile so you can get the backup and also import objects down the road.  If anything bad happens
(like loss of power or other tragedy) during a decompile, you will lose the database.  You might also lose just parts ... and no way to definitely know this right away.
0
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
Out of the literally 1000s of times I've done Decompile, only once has it trashed a db ... and that is once too many.
0
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
@Bruce ...
You mentioned you are operating in a Trusted Location. Cool.
What about this setting:

Macro InSecurity
0
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
BTW RE "not able to get the ACCDE to execute any code that is located in any of the the app's modules."

What exactly does happen? Do you get errors?  

Also, since you were able to actually create and ACCDE (right?), by definition your ACCDB version would have to have been Compiled, because you cannot create an ACCDE IF ... your ACCDB has any compile errors.
0
crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
adding onto Joe's comment
you can also choose Disable all macros with notifications, in which case you acknowledge it is okay to run
0
crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
[Joe, I seem to be behind on comments so am responding to your comment "before" mine ... good thoughts]

my guess is that the problem will come down to libraries  ... or maybe, as I found out recently, code that changes security settings (makes the accde ok because it is ok to run as accdb but once it is an accde it is not ok to run).
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.