Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Microsoft: Office FAQ

VB for apps

How do I add in a custom Macro/Function? by logius
Posted: 13 Nov 01

When using an Office product, it is sometimes necessary to create your own custom functions or macros to aid in your automation processing.  To create a custom macro/function is relatively easy.  Simply follow these steps:

     1. Make sure you have an Office product open then
        hit ALT+F11.  You should see Microsoft Visual
        Basic editor open in a separate window.

     2. Decide where you wish to include your custom
        method.  If you'd like to have your macro
        available everytime you open the application,
        then click on the appropriate folder:
             Excel: PERSONAL.XLS
             Outlook: Project1
             Word: Normal
        If, instead, you would like to associate your
        macro only with a specific file, then click on
        that file.
      3. Once you have selected the appropriate file,
         right-click on it and select Insert>Module.
         An editor screen should open up which will allow
         you to type in your custom function/macro.

A few points to remember:

      In order to run a custom Macro, you can hit ALT+F8 and select the macro you wish to run or you can go to Tools>Macro>Macros.

      In Excel, if you wish to run a custom function, then you simply type in the function as you would any other function.

Back to Microsoft: Office FAQ Index
Back to Microsoft: Office Forum

My Archive

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close