I tried to import a project from a Primavera cloud file with version 21.12.
When I open it with Aspose, I get a different project than the one Primavera displays.
Do you have any idea why it’s importing a different project?
Unfortunately, I cannot put the file here as it is confidential.
@Nour_From_XLSTAT ,
Primavera files can contain more that 1 projects. Maybe your file contain several projects.
Aspose.Tasks opens first project by default.
You can get projects uids from your file using GetProjectUids method (see the example):
If that’s not the case, I can’t suggest another idea without seeing the input file.
I was finally able to get the ProjectUid, thanks for that!
I also noticed that with an .xer 20.12 I could import the project I had saved in Primavera, but with an .xer 21.12 I have to enter the projectUid to import the correct project. Could you please explain this difference?
@Nour_From_XLSTAT ,
it is hard to say without seeing both files.
Maybe order of projects is different in .xer 20.12 and in .xer 21.12 files and in 20.12 file the correct project is in the first position.
You can check it by opening XER file in notepad and searching for “%T PROJECT” line:
%T PROJECT
%F proj_id fy_start_month_num rsrc_self_add_flag allow_complete_flag rsrc_multi_assign_flag....
%R 4558 1 N N Y N
%R 4570 1 Y Y Y N
%R 4571 1 Y Y Y N
Thanks to your previous answer, I understand that version 20.12 has only one project saved, which is why I’m accessing the correct project.
But is there a way to import the saved project into Primavera without checking the uid list? As in Primavera, “export_flag” indicates which project has been saved in the xer.
Alternatively, is it possible to ask directly for the project name, as you suggested with GetProjectUids, but have something like GetProjectName?
@Nour_From_XLSTAT
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.
Issue ID(s): TASKSNET-11191
You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.
About the “export_flag” argument, I have several projects, but only one has an export_flag set to yes (project 512) : image.png (2,2 Ko)
I thought this would be the only one I’d get after importing with Aspose, but I still have all the other projects too, is there an option to tweak to make it work as expected?
@Nour_From_XLSTAT ,
when you explicitly check the project in Primavera Export dialog , the export_flag is set to ‘yes’.
When several projects are selected, export_flag for each selected project is set to ‘yes’
The export_flag is set to ‘No’ when the project is not selected for export by the user, but is exported by Primavera due to external relationships with other exported projects.
@Nour_From_XLSTAT
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.
Issue ID(s): TASKSNET-11192
You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.
I’ve found that MPXJ has the behavior I’m asking for and I hope we’re on the same page about this improvement.
By default MPXJ reads the first project it finds in the file which has been marked as the “exported” project, otherwise it will simply read the first project it finds.