• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 461
  • Last Modified:

enable vba callback code in access 2007

I am trying to use VBA callbacks to customize my ribbons..However even the simplest of button click is not working....
I came across this statements...

"One limitation is that code must be enabled in the database for the code to run."

If you use VBA callbacks, the database must be opened in enabled mode for the code to run.  You may receive an error in Beta 2 when opening a database with custom ribbons in disabled mode.

where is this option that enables mode for the code to run?? I cant find it anywhere...
I am able to make the button appear in the database, but when i click on it nothing happens...its not calling the vba code, even if i just have a msgbox statement..

  • 3
1 Solution
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
See these links I am accumulating for A2007 - a good reference in general:

http://msdn2.microsoft.com/en-us/library/bb203849.aspx  'Transisitioning to A2007

http://support.microsoft.com/ph/11265    ' Various A2007 Issues  

http://blogs.msdn.com/access/archive/2006/06/05/618366.aspx    'A2007 Limitations list

http://allenbrowne.com/Access2007.html   ' A bunch of good stuff

http://msdn2.microsoft.com/en-us/library/aa722523.aspx    'Ribbon
Pra4444Author Commented:
I have gone through most of the links...but cant find where to enable it...
I just want to know, how to enable vba callback code for a particular database....
When you open the Access 2007 database, right under the ribbon bar, you should see a "Security Warning   Certain content in the database has been disabled" followed by a button that reads "Options..."
click on that Options button, and a "Security Alert" dialog opens up....select the radiobutton for "Enable this content", click "OK"...the database is now in "Enabled" mode.
Pra4444Author Commented:
yeah i remember that..but i dont remember what i clicked...!!! it was a day or so ago, when i was fooling around...hmm...
but it doesnt ask that anymore...
Pra4444Author Commented:

You did point to me in the right direction..i went to access options->trustcenter-> clicked trust center settings and selected the radio button Show the message bar in all applications

so , after i closed and opened it again, it gave me the security error and when i enabled it, my vba code worked like a charm..

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now