Task Serial View

M

Marcelo K

Does anyone have VBA code to create a Tasks Serial View, where for each
resource I can see, on one line only, the succession of tasks in a timeline?
Shouldn't this be a basic MS Project view?
Thanks,
Marcelo K
 
M

Marcelo K

Maybe I needed to clarify that I am looking for a "GANTT" like visual pane,
with bars for each task, but instead of having each resource's task on ist
own line I'd like to have them on the same line, one after the ohter wiht the
right bar length. One line per resource.

The reason I need this is that I work on projects with thousands of tasks
and docens of resources. I want to have a visual representation (a view) that
is simple to follow and that fits on 1-2 pages/screens height.
this view would also help the people themselve to "see" more clearly the
sequnece of tasks assigned to them.
(I don't care about parallel tasks overlaping)
 
J

Jan De Messemaeker

Hi Marcelo,

Noo, I don't have it readily here, but I recall making this for a customer
some 5 years ago.
My solution was to not create view in the project, but to create a new
project with the appropriate tasks (arranged in resource order)
Taht because if a task has 2 asignments to it, you need to make two tasks of
it because you need a bar for each resource.

The main logic stream then becomes:

For each Worker in OriginalProject.resources
'Create the same resoruce in NewProject
'Create a "resource task" in new project
'Position it on outlinelevel1
'Hide the task bar
For each Assgt in worker.assignments
'Create an assignment task
'Position it on OutlineLevel2
'Make it roll up to the summary bar
next assignment
next worker

Hope this helps,
 
M

Marcelo K

Unless I missed something, when you roll-up the sub tasks you will only see a
continuous black line extending for the total duration of all the sub-tasks.
I still wanted to see each task individually represented in the line
Hoping for quasi-fixed pitch font, I try to draw an ASCII example below:

1 1 1 1 1 1 1 1 1
7 8 9 0 1 2 3 4 5 6 7 8.... dates

+-------------++--------------------------------++---------------------------+
Homer S. | Write doc || Implement module | | Test
Module |

+-------------++--------------------------------++---------------------------+

+-------------++-------------------++---------------------------+
Sally M. | Prep || Stage1 || Stage 2
|

+-------------++-------------------++---------------------------+

.....and so on, one line for each resource.

I hope the drawing was understandable
 
R

Rod Gill

Note also that unless you have the timescale set to hours or at most days
and very short task names, this format doesn't work as task names get cut
off. For an overview try just displaying summary tasks and maybe level 1
tasks.
 
M

Marcelo K

I did progress with that but I still have a little bit of trouble copying all
the assignements for each resource. I use the code:

Private Sub CreateResGroup(r As Resource)
Dim header as Long
Dim asg As Assignment

'Add a summary task with the name of the resource
header = ActiveProject.Tasks.Add(r.Name)
ActiveProject.Tasks(header).SetField pjTaskOutlineLevel, "1"

'Copy the resource assignments, make it "subtask"
For Each asg In r.Assignments
newasg = ActiveProject.Tasks.Add(asg.TaskName)
With ActiveProject.Tasks(newasg)
.Start = ass.Start
.Finish = ass.Finish
.Work = ass.Work
.Estimated = "No"
.Milestone = "No"
.SetField pjTaskOutlineLevel, "2"
.SetField pjTaskRollup, "Yes"
End With
Next asg
End Sub

This code does not copy well split tasks, instead each split task becomes a
continuous task from stat to end.

A second problem I encountered when rolling up the tasks to the summary. I
chose the inside bar text to be the task name. But I cannot find how to
wrap/crop the text so it doesn't "invade" the next task in line.
 
M

Marcelo K

Sorry about the variable name, I tried to rename it to "asg" for this post,
but I missed some. The code runs.
 

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