Hide/disable certain buttons on custom ribbon bar in access 2007

Posted on 2014-07-13
Last Modified: 2014-07-14
I have created a custom ribbon bar for my A2007 DB but wanted to know if there was a way to disable and/or hid certain buttons on the ribbon based on a users permission level? I have a table called "tblEmployees" where I can add permission levels but I want to be able to disable certain buttons on the custom ribbon bar. Is this possible? If so, can anyone shed some light on how I would do this?
Question by:Lawrence Salvucci
    LVL 24

    Assisted Solution


    this is done using Callback functions which must be in a standard module and declared as Public. You can find all the details about ribbons including demo databases and code snippets here:


    LVL 1

    Author Comment

    by:Lawrence Salvucci
    I understand how to enable them and disable them but how do I do it based on a user's permissions?
    LVL 4

    Assisted Solution

    by:Jack Leach
    By using a callback function, you gain access to your entire project via VBA, so you can then check for any active user/permissions from within your code, and return your callback values accordingly.

    I forget the attribute name offhand, but the visibility/enabled status will be set according to whatever the callback returns, thus you have the entire project at your disposal for logical handling through the callback.

    LVL 48

    Accepted Solution

    Yes, it is possible, but it will be a lot easier for you if you implement the ribbon class module from Albert D. Kallal:


    Featured Post

    Do You Know the 4 Main Threat Actor Types?

    Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

    Join & Write a Comment

    In the previous article, Using a Critera Form to Filter Records (, the form was basically a data container storing user input, which queries and other database objects could read. The form had to remain op…
    I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
    Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
    With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…

    729 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

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now