We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Format of chart is changed while removing first slide (Problem in Aspose - Slide Java version 3.0)

Dear Team,

Our requirement is to create new pptx file from existing pptx. Existing pptx slide has one chart. So we are cloning this slide to new pptx.

Whenever we create a new pptx file, first slide comes automatically by aspose. We dont require this slide. So, we are removing this firstslide (using remove() method), but chart format is also changing automatically.

Code:
private static void croppptxchart(String inpptx, String outpptx) {

File xfile= new File(outpptx);
FileOutputStream fos;
try {
fos = new FileOutputStream(xfile);
PresentationEx newpptPresentationex=new PresentationEx();
PresentationEx pptPresentationex= new PresentationEx(inpptx);
SlidesEx oldslides = pptPresentationex.getSlides();
SlideEx oldslide = oldslides.get_Item(0);
SlidesEx newslides = newpptPresentationex.getSlides();
newslides.addClone(oldslide);
// newslides.removeAt(0); (When we remove slide by uncommanding this line, default slide is deleted and also format is changes)
newpptPresentationex.write(fos);
fos.flush();

} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {

e.printStackTrace();
}
}

We used aspose 2.9.6, the chart format is not changed. This is the problem with Aspose 3.0 version only.

We attached input,output and java file also

Input File : input_1.pptx

O/p File : output_1.pptx (This pptx has default slide and chart format is not changed)

O/p File : output_2.pptx (Default slide is removed and chart format is chaged)

Java File : POCII.java

Hi Ramgopal,


I have worked with the presentation file shared by you and have been able to observe the issue specified. An issue with ID SLIDESJAVA-33571 has been created 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 automatically notified once the issue will be resolved.

We are sorry for your inconvenience,

Hi Team,

The issue is with the chart type and it is assigning wrong chart type…

As we are getting the chart type by using getType() method it is giving perfect int value which is same as MS provided but while rendering its giving some other chart

Other thing is it is working for some types of charts like Barcharts.

Is there any patche for handling this as this is working in aspose 2.9.6


Hi Ramgopal,


Thank you for the elaboration. I have observed that if you remove the default slide then chart type changes from Stacked Line With Marker to Line With Marker. I have updated the issue status as well. I regret to share that chart support has been provided for the first time in Aspose.Slides for Java 3.0.0 and was not there in older product versions.

We are sorry for your inconvenience,

The issues you have found earlier (filed as SLIDESJAVA-33571) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.