Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Populate a specific cell with Macro in MS Project

Status
Not open for further replies.

Prashsh

Programmer
Jul 20, 2009
1
US
Hi

How can I populate a specific cell when the Macro in MS Project 2003 calculates a value.
For example, in the below code, I want to polutate the 2nd row, 11th column “cell” in my MPP file with the result that comes from Effort.

Set ts = ActiveProject.Tasks
If t.Text5 = "BL" Then
Effort = Effort + t.Number3
End If


Thanks

 
Prashsh
I don't really understand what you're after - Project isn't like Excel. Rows are Tasks and columns (task properties) can appear wherever you want them. In your case I suspect you mean Work rather than Effort so perhaps your code should read:
Code:
Dim T as Tasks
For Each T in ActiveProject.Tasks    
 If T.Text5 = "BL" Then T.work =T.work+ T.Number3        
Next T
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top