Hi,
While converting attached sample, I see that ‘Predecessors’ column in missing in output.
My guess is all (may be manually added) columns other than Task Name, Duration, Start, and Finish will not be appearing in PDF.
Can you pls check and let me know.
Thanks,
Rajiv
Hi Rajiv,
Thank you for contacting Aspose support.
Please use following code to display Predecessors column and you may use this code to display other columns as well. Please feel free to write us back if you have other queries in this regard.
Sample code:
private static Project prj = new Project(“Sample.mpp”);
public static void TestPredecessorsFields()
{
SaveOptions options = new PdfSaveOptions();
options.setTimescale(Timescale.Months);
options.setView(ProjectView.getDefaultGanttChartView());
options.getView().getColumns().add(new GanttChartColumn(“Predecessors”, 100, new TaskToColumnTextConverter() {
@Override
public String invoke(Task task)
{
//return Double.toString(task.getBcws());
String strPredecessors = “”;
java.util.List predecessors = prj.getPredecessors(task);
for(TaskLink taskLink : predecessors)
{
strPredecessors += taskLink.getPredTask().getId();
strPredecessors += “,”;
}
return strPredecessors;
}
}));
prj.save(“D:/Aspose/result GanttChart_Java.pdf”, options);
}
Hi Kashif,
Do we have to hard-code the column name and populate it this way ??
I mean isn’t there any way to extract all the columns present in source file without doing this for each column. One reason is I may not know what all columns any MPP file (coming for processing in our application) may have, and second there may be large number of columns, so it’s difficult to traverse through them this way. I would like to keep all columns as per source document.
Is it possible ?
Thanks,
Rajiv
Hi Rajiv,
I have analyzed your requirement and have logged an enhancement ticket id:TASKS-33705 in our issue tracking system for further investigation by our development team. Once there is any information available in this regard, we’ll update you here via this thread.
Hi Kashif,
We don’t think this is really an ‘enhancement’ request. If there’s a data loss, and we don’t have any feasible way to retain all data from source file, then it’s obviously a defect.
We would like you to trace this issue as defect and make its severity HIGH as it’s a data-loss issue, and get it analyzed by your dev asap.
Thanks,
Rajiv
Hi Rajiv,
Priority of this issue has already been raised to Enterprise Support and development team will look into it on its turn. We’ll update you here once there is any information available in this regard.
The issues you have found earlier (filed as TASKS-33705;TASKS-33705) have been fixed in this update.
This message was posted using Notification2Forum from Downloads module by Aspose Notifier.
The issues you have found earlier (filed as ) have been fixed in this Aspose.Words for JasperReports 18.3 update.