I have a simple solution created where I have one parent task and two children. I’m setting the required properties, or at least at this point what I think needs to be set, and the output file is not entirely correct.
Scenario 2.zip (74.8 KB)
Scenario 3.zip (75.4 KB)
Scenario 1.zip (76.9 KB)
I’ve uploaded three sample solutions (Keep in mind that I have Project Calculation Mode set to “NONE” in all scenarios). Scenario 1 contains the entire solution and Scenario 2 and 3 only contain the template/generated output file and updated aspx.cs file:
In the Scenario 1 upload I’m only setting the task “Percent Work Complete” and “Percent Complete” values to be 100% for the “CHILD 2” task. In the generated project file it has no affect (meaning the task is not marked as complete…Actual Duration, Actual Work are 0 and the Actual Start and Finish is NA). What else should I be setting here to mark the task as complete?
In the Scenario 2 upload I’m setting the “Actual” and “Remaining” values (Actual Duration, Actual Work, Actual Start and Finish, Remaining Work and Remaining Duration) in addition to the percent complete fields in scenario 1. In the generated project file all values seem to be correct. At this point if I were to select the incomplete task “CHILD 1” and select the 100% button to mark the task as complete it doesn’t set the actual work or actual finish date values correctly (actual work remains at 0 and finish is set to NA). It seems like I’m not setting all the correct values via Aspose.Tasks that will facilitate the complete action in MS Project. Can you tell me what I’m missing here?
In the Scenario 3 upload in addition to setting all values in the previous two scenarios, I’m trying to add a resource to the CHILD 1 and CHILD 2 task. In the generated project file the finish date for the “CHILD 1” task is showing as 5:00 PM when the work value associated to the task is only 1 hr (since this task is schedule to start at 8:00 AM it should finish at 9:00 AM). All values displayed for the “CHILD 2” task seem to be correct at this point. If I were to perform a calculate project at this point, by selecting from the Project menu, the Actual Duration and Duration values are zeroed out for the completed task “CHILD 2”. If I then try to save I get the “The file cannot be opened.” error. It seems like project is expecting values that I’m not setting via code. Are you able to provide me with a working sample, where Aspose.Tasks is creating a parent task with two children of which one child is complete and both have a resource assigned?
I’m using Aspose.Tasks 17.1.0, VS 2010 and MS Project 2010. I’ve include my starting template in all uploads “blank.mpp” and the generated output file is “AsposeCompleteTaskIssue.mpp”.
If you need any further information, please let me know.