How to get out the Resource usage data

We want to get out the resource usage data by date. How to deal with this Task add in.

bs

jens

Hi Jens,


Thank you for contacting Aspose support team.

Resource usage data by date can be obtained by reading the Timephased Data by providing the start and end date for a particular resource. Following is a sample code which can be used to read the resource usage by date:

//Load the file
Project project = new Project(@“Sample.mpp”);

//Get the Resource by its ID
Resource resource = project.GetResourceByUid(1);

// Print Timephased data of ResourceWork
Console.WriteLine(“Timephased data of ResourceWork”);
foreach (TimephasedData td in resource.TimeScaleData(project.StartDate, project.FinishDate))
{
Console.Write(“Start: " + td.Start.ToShortDateString());
Console.Write(” Work: " + td.Value + Environment.NewLine);
}
Please feel free to write us back if you have any other query in this regard.