Add new task

M

Mike

I am new here and this is surely an easy question.
I am trying to create a macro that creates a new activity.

I have some linked tasks (and lag>0) with equal numbers
in Text23:

Task name Duration Start Finish Text23
a 3 days Wed 03-12-03 Fri 03-12-05 124
b 4 days Wed 03-12-10 Mon 03-12-15 124
c 5 days Wed 03-12-17 Tue 03-12-23 124

My new task will have the following data:
new 15 days Wed 03-12-03 Tue 03-12-23

It starts when first task (a) with same value in Text23
starts and
finish when last task with same value in Text23 finishes.

I have other values in Text23 for other tasks and want
the same thing to happen for those.

Any help appreciated

Thanks in advance,
Mike
 
R

Rod Gill

Hi,

You will have to use VBA code to determine what tasks to link. If you need
two links to the same task (EG to drive its finish date), then you need to
copy paste special dates. Edit and use:
SelectTaskField Row:=ActiveProject.Tasks("a").ID, Column:="Finish",
RowRelative:=False
EditCopy
SelectTaskField Row:=ActiveProject.Tasks("b").ID, Column:="Start",
RowRelative:=False
EditPasteSpecial Link:=True, Type:=2, DisplayAsIcon:=False

NOTE: project.vba news group will be closing down soon. Please use the new
project.developer group from now on.

--
Rod Gill
Project MVP
For Microsoft Project companion projects, best practices and Project VBA
development services
visit www.projectlearning.com/
 

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