none
How to share macros as part of a project file? RRS feed

  • Question

  • Using Project 2010 Pro with Project Server.  All project updates are done through the client. Server is only used for saving the files and checking them in/out.

    I've created some macros (with the help of these forums, thank you!) that are saved in the Global.MPT! file.  I had assumed that these macros were part of the file, and further, that since I was saving the file on the server, the macros would be available to anyone who opened the file from the server.

    I just discovered today that they are not part of the project file, and found the info below in an earlier forum posting:

    In Project, the "global macros" are stored in the file global.mpt and are available via Project to be used when any Project *.mpp is opened.  This global.mpt file is on your computer.  Thus, when you open a *.mpp file (even if it was provided by someone else), Project lets you run your own global macros because they are in your copy of global.mpt.  They are not in the *.mpp file or the file sent to you.

    To have any macro you want to be available to all the time no matter what *.mpp file is opened, put them in your global.mpt file.  I do this by collecting my library of macros into a module called "rms" that is stored in my global.mpt.  Normally it just stays there.  There are times I'll want to include that module in a Project file, so I just copy it (Menu:Tools/Organizer...) into the target file.  Then the target *.mpp file has that module.  If I were to send that *.mpp file to someone else and they open the file, they will be able to use those macros stored in that module which are in that *.mpp file.  

    My question -- how do I make these macros part of the file itself so that they are available to anyone who wants to run a report with them? The instructions above don't seem to correspond to menu options I see in Project 2010 Pro. 

    From some of the reading I did, it looks like I need to get these macros into the Enterprise global file so they are available to everyone, but I don't have a clue how to do that. 

    Once again, thanks for any help you can provide.

     


    Betty in NJ
    Tuesday, February 15, 2011 9:53 PM

Answers

  • Hi Betty,

    in addition Rob's great answer...

    You wrote that you are using Project Server. So open Enterprise Global, and do what Rob described for Global.mpt for Checked-Out Enterprise Global

    • Take an Administrative Backup of Enterprise Global
    • File - Info - Manage Global Template - Open Enterprise Global
    • File - Info - Manage Global Template - Organizer
    • Open tab Modules
    • Make sure that you have Checked out Enterprise Global is selected on the right or left and the Global (+non-cached Enterprise) (containing your macros) is selected on the other side.
    • Copy your Modules to Checked-Out Enterprise Global
    • Save Enterprise Global
    • Close Enterprise Global
    • Close Project
    • Re-start Project
    • Ask someone else to re-start Project to check, if macros are available.
    • If they are available, delete them from your global.mpt (to avoid having macros twice on your computer)

    Hope that helps!
    Barbara

    • Marked as answer by Betty in NJ Wednesday, February 16, 2011 3:17 PM
    Wednesday, February 16, 2011 8:53 AM
    Moderator
  • Betty,

    Pre Project 2010 you would use Menu: Tools/Organizer to move macros (and other things) between the file and the global.mpt file. In Project 2010 that same function has moved to Menu: File/Info and then see "Organize Global Template".  From there it looks the same as before.  There is a "Help" button on the dialog box that you can read to get more info.

    If you do it this way, if/when you make changes (which are inevitable) instead of changing in one place (the standard global.mpt that get re-distributed), you have to update all the MPP files in which you want the macros included.  Starts to become an issue when there are lots of files involved.

    I find it easier to version control code in one global.mpt file rather than many MPP files.  Re-distribute the global.mpt file to all users when changes to code is required.  This creates a neat separation between code and the project. Just my two bits.


    --rms www.rmschneider.com
    Wednesday, February 16, 2011 8:35 AM

All replies

  • Hi Betty,
     
    Try posting on the Project Server General Questions and Answers forum:
    http://social.technet.microsoft.com/Forums/en-US/projectserver2010general.  Please see FAQ Item: 52 Find a Forum.   FAQs, companion products and other useful Project information can be seen at this web address:  http://project.mvps.org/faqs.htm
     
    Mike Glen
    Project MVP
     
     
    Tuesday, February 15, 2011 10:31 PM
    Moderator
  • Betty,

    Pre Project 2010 you would use Menu: Tools/Organizer to move macros (and other things) between the file and the global.mpt file. In Project 2010 that same function has moved to Menu: File/Info and then see "Organize Global Template".  From there it looks the same as before.  There is a "Help" button on the dialog box that you can read to get more info.

    If you do it this way, if/when you make changes (which are inevitable) instead of changing in one place (the standard global.mpt that get re-distributed), you have to update all the MPP files in which you want the macros included.  Starts to become an issue when there are lots of files involved.

    I find it easier to version control code in one global.mpt file rather than many MPP files.  Re-distribute the global.mpt file to all users when changes to code is required.  This creates a neat separation between code and the project. Just my two bits.


    --rms www.rmschneider.com
    Wednesday, February 16, 2011 8:35 AM
  • Hi Betty,

    in addition Rob's great answer...

    You wrote that you are using Project Server. So open Enterprise Global, and do what Rob described for Global.mpt for Checked-Out Enterprise Global

    • Take an Administrative Backup of Enterprise Global
    • File - Info - Manage Global Template - Open Enterprise Global
    • File - Info - Manage Global Template - Organizer
    • Open tab Modules
    • Make sure that you have Checked out Enterprise Global is selected on the right or left and the Global (+non-cached Enterprise) (containing your macros) is selected on the other side.
    • Copy your Modules to Checked-Out Enterprise Global
    • Save Enterprise Global
    • Close Enterprise Global
    • Close Project
    • Re-start Project
    • Ask someone else to re-start Project to check, if macros are available.
    • If they are available, delete them from your global.mpt (to avoid having macros twice on your computer)

    Hope that helps!
    Barbara

    • Marked as answer by Betty in NJ Wednesday, February 16, 2011 3:17 PM
    Wednesday, February 16, 2011 8:53 AM
    Moderator
  •  

    MS Project is incredibly powerful, but also incredibly complex. I'm always amazed at the wealth of knowledge shared on these forums.

    Once again, thank you to all for your help!


    Betty in NJ
    Wednesday, February 16, 2011 3:22 PM