macro to copy formulas and graphical indicators

L

Lynn

anyone has a macro to copy formulas and graphical indicators from 1
project file to another?
 
M

Mike Glen

Hi Lynn,

Welcome to this Microsoft Project newsgroup :)

You don't need a macro. Use Tools/Organizer to copy them to either your
Global.mpt for use in any project, or to another project.

You might like to have a look at my series for beginners on Microsoft
Project in the TechTrax ezine, particularly #32 on the Organizer, at this
site: http://tinyurl.com/2xbhc or this:
http://pubs.logicalexpressions.com/Pub0009/LPMFrame.asp?CMD=ArticleSearch&AUTH=23
(Perhaps you'd care to rate the article before leaving the site, :)
Thanks.)

FAQs, companion products and other useful Project information can be seen at
this web address: <http://www.mvps.org/project/>

Hope this helps - please let us know how you get on :)

Mike Glen
MS Project MVP
 
R

Rob Schneider

Lynn said:
anyone has a macro to copy formulas and graphical indicators from 1
project file to another?

Lynn,

I'm assuming that you have these forumulae and graphical indicators in
Project's Custom fields?

If yes, then the first step would be to use the "Organizer" (Menu:
Tools/Organizer...) to copy them from where they are to where you want
them to go.

If this isn't sufficiently automated, then you could write code in VBA
A way to jump-start that would be to record a new "macro" in VBA using
the built-in capablity (Menu: Tools/Macro/Record New Macro ...). Once
recorded and saved you can then edit and make it as sophisticated and
automated as you like.
 
L

Lynn

I tried using macro recorder to copy the custom fields but the formula
in the field does not get copied
 
R

Rob Schneider

Lynn said:
I tried using macro recorder to copy the custom fields but the formula
in the field does not get copied

Surprising. Oh well.

Then I guess you use the Organizer.

Perhaps use the macro in VBA to recreate the Custom field on the target
site. I know the latter works as I use a macro to "reset" all custom
fields in a new MPP file. See how that works to initially setup by
using macro recorder as you create/edit a custom field. Take results
from the recording and put into your VBA.
 
R

Rob Schneider

Lynn,

Easier and more productive if you do it yourself.

1. Turn on macro recorder
2. define all custom fields
3. turn off macro recorder
4. look a the code created. tweak it.
5. copy the code into a module and give it a sub name, say "sub
ResetCustomFields()"
6. put that module in global.mpt
7. assign a toolbar button in global.mpt to run that command

Once you see the code that's created by the macro recorder, you'll
detect the pattern and you can do yourself.
 
S

Storm

anyone has a macro to copy formulas and graphicalindicatorsfrom 1
project file to another?

Lynn, first, did you get the answer you need? If not, what is it that
you really want to do?

1.) Just get field properties to another project schedule as needed,
i.e., copy the properties from say "Text6" in one file to "Text6" in
another file?
2.) Take a new project schedule and at any time add a standard set of
fields to the project with properties like formulas, valuelists etc.
that you have defined, but you don't want to keep a copy of the fields
in the Global.mpt template (which may overwrite fields in someone
else's project schedule?
3.) Press a button that copies only the graphic indicators from a
field in one file to he same or different field in another
schedule?
4.) Just move Graphic indicators that you have defined to other custom
fields in another file, but only once in a great while?
5.) Other?

Several options are available to you to transfer or add properties -
formulas, valuelists, and or graphic indicators to custom fields, but
what I don't know which method to provide that will give you what you
want. Please clarify your need.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top