E
Eugene Rokhlin
Hi All,
I get an error 1101 'The argument value is not valid' trying to set the
ActualCost and ActualWork properties of the task
The code is as simple as that:
Set objTask = m_objActiveProj.Tasks.Add
With objTask
.Name = rs.Fields("Description")
.WBS = rs.Fields("WBS")
.ActualStart = Format(rs.Fields("dtSchedStartDate"), "dd mmm
yyyy")
.ActualFinish = Format(rs.Fields("dtSchedEndDate"), "dd mmm
yyyy")
.ActualCost = rs.Fields("mActualCost")
.ActualWork = rs.Fields("nActualHours")
End With
Other properties are set successfully.
I even tried to set ActualCost and ActualWork to some integer or variant
constants, but still get the same error.
What should I do?
P.S. I turned off "Actual Costs are always Calculated by Microsoft project"
in Tools, Option, Calculation, but this did not help so far..
Thanks.
I get an error 1101 'The argument value is not valid' trying to set the
ActualCost and ActualWork properties of the task
The code is as simple as that:
Set objTask = m_objActiveProj.Tasks.Add
With objTask
.Name = rs.Fields("Description")
.WBS = rs.Fields("WBS")
.ActualStart = Format(rs.Fields("dtSchedStartDate"), "dd mmm
yyyy")
.ActualFinish = Format(rs.Fields("dtSchedEndDate"), "dd mmm
yyyy")
.ActualCost = rs.Fields("mActualCost")
.ActualWork = rs.Fields("nActualHours")
End With
Other properties are set successfully.
I even tried to set ActualCost and ActualWork to some integer or variant
constants, but still get the same error.
What should I do?
P.S. I turned off "Actual Costs are always Calculated by Microsoft project"
in Tools, Option, Calculation, but this did not help so far..
Thanks.