Results 1 to 2 of 2
  1. #1
    Harley Guy is offline Advanced Beginner
    Windows XP Access 2003
    Join Date
    Apr 2010
    Posts
    57

    Creating Macro from Module


    Thanks to Rural Guy, I've been able to get the coding to copy one database to another...

    Now that has been accomplished, I need to create a macro that calls to the module that I have created.

    The module I've created that copys the table to another database is called Archive Current Server List.

    I've been looking at the "RunCode" option but I have no idea how to call to the coding in the module to run it.

    If I use the "Open Module" option, then it opens the module and you need to run the module from there.

    I need to limit users from getting in this area as you know people could inadvertanly screw up the coding.

    Any ideas?

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 Access 2010 (version 14.0)
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    I take it you have your code in a Standard Module? Be sure the Module name and the Procedure name are not the same. I would name the Module something like basCode. If you are going to invoke the procedure from a button on a form then you can simply Call the procedure. BTW, embedding spaces in any names will be problematic down the road.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Calculating Interest with a Module
    By jgelpi16 in forum Modules
    Replies: 2
    Last Post: 09-30-2012, 05:08 AM
  2. Running module from Macro
    By Harley Guy in forum Modules
    Replies: 6
    Last Post: 10-27-2010, 11:05 AM
  3. How to pass what was clicked to module?
    By nichojo in forum Modules
    Replies: 11
    Last Post: 07-22-2010, 08:27 AM
  4. need help with import Module
    By marubal21 in forum Modules
    Replies: 1
    Last Post: 07-22-2010, 12:23 AM
  5. Module not found
    By nooby in forum Modules
    Replies: 1
    Last Post: 12-02-2009, 02:20 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums