Free Support Forum - aspose.com

Urgent : Unable to add resources from central resource pool

I have purchased aspose.tasks but failed to get desired results. The problem i am facing now is that i am unable to create .mpp file and also i am not able to add resources in multiple project files from central resource pool. Please guide me in this regard and let me know any alternative way to create .mpp file. Waiting for ur response

Sorry, that’s not possible to save data back to mpp format.
You have to save it to mpx or xml.

how could i add resources from central resource pool to my new created project file programatically and is there any way i may create .mpp file using xml. please answer both questions urgently.

As I wrote it’s not possible to save project in mpp format.
You can save it as xml, open xml with MS Project and save it as mpp.

To add new resource you should open your mpp (or another format) file
add new resource and set some properties. For example:

MPXFile mpx = new MPPFile (“project.mpp”);
Resource resource1 = file.AddResource();
resource1.Name = “New Resource”;
resource1.AvailableFrom = new System.DateTime(2006, 3, 21);
resource1.AvailableTo = new System.DateTime(2006, 3, 25);

The scenario is that resources are saved in file "Resource.mpp" as a central resource pool file. I am trying to add resource from this file into a newly created file say "project.mpx". It adds programmatically and throws no exception but when i open project.mpx file it gives me error stating " resource id invalid". Please give me its solution

Did you set auto numeration for all Ids (check MpxCreate demo) ?