Using a module to refference/control navigation buttons on a subform

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • John Phelan-Cummings

    Using a module to refference/control navigation buttons on a subform

    In the process of polishing up my (last) beta application; I have been
    exploring all the possible ways of speeding up my forms. I realized that
    numerous a forms under various application modules/suites lots of the
    same navigation buttons.

    I thought of creating a macro to handle all this, and just reference the
    macro, etc, in order to reduce the amount of forms coding/duplication
    from form to form. However, I have no idea of where macros are going in
    future
    versions of MS Access. I thought about using a single VBA/module, or
    different modules, for handling each of the commands.

    I since used code for a module containing all the navigation commands to
    be referenced from the different forms that I use with my own navigation
    buttons.
    This works as along as the navigation button is located on the main form
    with the following code in the, "On Click" for the e.g., Previous
    button:

    =navtoPrevious([activecontrol].[parent])

    If I want to place the same code on a sub form it does not work. Since
    this only seems to works on main (parent) forms, I have also tried the
    following, also without success:

    Retval= navtoPrefious(M e),

    and,

    Call navtoPrevious(M e),

    and, finally,

    navtoPrevious Me

    None of these options seem to work. So, I'm back to square one in
    getting all this to work. Has it ever been done before? Are ther any
    models, articles, ideas, or code samples out there to study/use?

    Thanks,
    John



    *** Sent via Developersdex http://www.developersdex.com ***
Working...