We are currently evaluating Aspose.Tasks and are facing difficulites with the pdf rendering of a mpp file.
We use Aspose.Task for java and need to load and save an existing mpp file to pdf with the same rendering (for example : fit to one page).
How can we achieve this whit Apose.Task for java ? Can you please provide sample code ?
Please find in attachment the mpp file we want to save in pdf format, the print preview from MS-Project to show the expected result and the current PDF result.
We need to investigate this on our end and a ticket with ID TASKSJAVA-1291 has been added in our issue tracking system to further investigate and resolve the issue. This thread has been linked with the issue so that you may be notified once the issue will be fixed.
@mudassir.fayyaz Good morning. Do you have any update about ticket TASKSJAVA-1291 ? Can you please give me a resolution delay ? We have bought Aspose.Total License and we really need this ticket to be fixed to go ahead in our project.
The concerned issue is going to be fixed in upcoming Aspose.Tasks for Java 21.2. We request for your patience and will share the good news with you as soon as it will be shared online.
@mudassir.fayyaz Good morning. I’ve seen that ticket TASKSJAVA-1291 was resolved. Thank you for that.
I have downloaded the new release Aspose.Tasks for Java 21.2, but the issue is not fixed. I’m still not able to have the same rendering in pdf for fit to one page. Any Idea ?
@antoinegentet Hello!
We added a new option for export to graphical formats. Please, try the next code sample:
Project project1 = new Project("pce_exported_projet.mpp");
PdfSaveOptions saveOptions = new PdfSaveOptions();
saveOptions.setTimescale(Timescale.Days);
saveOptions.setPresentationFormat(PresentationFormat.GanttChart);
// set the option to render on a single page
saveOptions.setRenderToSinglePage(true);
saveOptions.setStartDate(project1.get(Prj.START_DATE));
saveOptions.setEndDate(project1.get(Prj.FINISH_DATE));
project1.save("output.pdf", saveOptions);
fit to one page works fine, but we have the following questions about pdf rendering :
How can we define the redering on max X pages vertically and max Y pages horizontally ?
For example, for a project of one month duration with a lot of tasks, I want to set max 1 page horizontally, and max 5 pages vertically. Or for a long duration project with few tasks, I want to set max 2 pages vertically and max 6 pages horizontally.
How can the tasks’ bar color be rendered in PDF ?
For example, we have defined some colors on tasks’ bar (see MS-Project print preview.png), but these colors are not rendered on the PDF.
Thank you. Just to be sure: as we mentionned earlier we use Aspose.Tasks for java. I just want to confirm that both issues will be fixed also for Aspose.Tasks for java ? Because both tickets are named TASKSNET-0000 and not TASKSJAVA-0000.
Aspose.Tasks for Java is a ported version of Aspose.Tasks for .NET, so we are trying to resolve the issues for .NET version at first. If we find the issues we would port it in the next Aspose.Tasks for Java version.
Can you please try using latest Aspose.Tasks for Java 21.3 on your end for issue pertaining to fixing of tasks bar styles in case of non-default name of Gantt chart view.