Hi
Tilll now i used the following macro to copy custom field content from the task tabelle to the assigment tabelle. So when i save the project it copy text5 from the gantt chart to text5 field in the ressource usage view.
This macro does not work in MS Project 2010. If i save the file als 2003 version it works more or less. It only works if delete the contant in text5 in the ressource usage and then save. So it does not perform updates.
I set the setting in the trust center to enable all macros.
what i wrong
Private Sub Project_BeforeSave(ByVal pj As Project)
Dim t As Task
Dim ts As Tasks
Dim A As Assignment
Set ts = ActiveProject.Tasks
For Each t In ts
If (Not t Is Nothing) Then
For Each A In t.Assignments
'change the following line to use
'for a different custom field
A.Text5 = t.Text5
Next A
End If
Next t
End Sub
Replies