Aspose.Slides.Pptx is not available in Aspose.Slides.dll version 14.3.0.0

Hi,

I am using Aspose.Slides.dll version 7.8.1.0 for .NET. I wish to update with latest version, but the latest Aspose.Slides.dll for net version 14.3.0.0 is not supporting below functionalities which is available in Aspose.Slides.dll version 7.8.1.0 for .NET.

1.presentation.Slides.LastSlidePosition

2.'Aspose.Slides.Presentation' does not contain a definition for 'Aspose.Slides.Presentation'

3.'Aspose.Slides.ISlideShowTransition' does not contain a definition for 'Hidden' and no extension method 'Hidden' accepting a first argument of type 'Aspose.Slides.ISlideShowTransition' could be found

4.'Aspose.Slides.Table' does not contain a definition for 'RowsNumber','ColumnsNumber','GetCell','ForeColor','BackColor', FontColor','TextFrame'and no extension method 'RowsNumber' accepting a first argument of type 'Aspose.Slides.Table' could be found

Please provide me the solution to over come this issue.

Hi Dhivya,

Thanks for inquiring Aspose.Slides.

I have observed the requirements shared by you and will try my best to address all of them.

Dhivya:

1.presentation.Slides.LastSlidePosition

The Slides.LastSlidePosition was used for PPT presentation formats in legacy API. In legacy API, there was single SlideCollection used to hold normal as well as master slides. So, it that case LastSlidePosition was used. However, in new API, we have separate Slides collections for Master, Layout and Normal slides, so ISlideCollection holds only normal slides. So, the size of ISlideColletion-1 is the last slide position.

Dhivya:

2.‘Aspose.Slides.Presentation’
does not contain a definition for ‘Aspose.Slides.Presentation’

Unfortunately, I have not been able to completely understand this requirement. Can you please share some more details about this.

Dhivya:

3.‘Aspose.Slides.ISlideShowTransition’
does not contain a definition for ‘Hidden’ and no extension method ‘Hidden’
accepting a first argument of type ‘Aspose.Slides.ISlideShowTransition’ could
be found

You may please try using ISlide.Hidden property in this regard to serve the purpose as the new API is based on PPTX format but support every thing of PPT format as well. For PPT presentations, the Hidden property was in fact in SlideShowTransition, where as in new API it is available in ISlide class.

Dhivya:

4.‘Aspose.Slides.Table’
does
not contain a definition for
‘RowsNumber’,‘ColumnsNumber’,‘GetCell’,‘ForeColor’,‘BackColor’,
FontColor’,'TextFrame’and no extension method
‘RowsNumber’ accepting a first argument of type ‘Aspose.Slides.Table’
could be
found

You may please try using the following sample code in this regard to serve the purpose.

Cell cell = (Cell)tanble[ ColumnIndex,RowIndex];

I also suggest you to please visit this documentation link for your further kind reference to see how to work with tables in new API.

I hope the shared information will be helpful to serve the purpose on your end. Please share, if I may help you further in this regard.

Many Thanks,

Hi,

How to get GradientColorType in Aspose.Slides.dll version 14.3.0.0 for .net?

This is available in old version.

Thanks,

Dhivya

Hi,

How to get GradientColorType in Aspose.Slides.dll version 14.3.0.0 for .net?

This is available in older version.

Thanks,

Dhivya

Hi Dhivya,

I have observed your requirements and like to share that in new API the GradientColorType is not available as it was used for PPT formats in old API. In new API, you need to use GradientStops and set their color. Please visit this documentation link for your kind reference in this regard.

Many Thanks,

Hi,

I need your help to fix the below issue.

Actually I am using the shape.FillFormat.GradientColorType == GradientColorType.OneColor and shape.FillFormat.GradientColorType == GradientColorType.TwoColors

to get the background and fore colors. If the Gradient color type is two that time i will read backcolor and fore color or else only i ll ready back color from FillFormat. But in New API the GradientColorType replaced with GradientStops. So i need the sample code to compare one or two color mode using the gradient type.

Thanks,

Dhivya

Hi Dhivya,

Please accept my apologies for delayed response. I
am investigating the issue on my end and will share the feedback with
you shortly in this regard.

Many Thanks,

Hi Dhivya,

I have observed the requirements shared and like to share that in new API there are GradientStops collection. The count of Gradient stops gives you information how may colors have been used for gradient fill. The following sample code will serve the purpose in this regard. Please share, if I may help you further in this regard.

int gradientcount=shp.FillFormat.GradientFormat.GradientStops.Count;

Many Thanks,

Hi,

We are developing the application to identify the hidden text from the PowerPoint documents.

Also working on to identify the text which the font color is same as the background color. If the shape color and the text font color is same that time also the text is not visible. So we are considering that shape text is hidden. But we are facing the issue to compare the text font color and shape color if the shape's filltype is gradient. Because the gradient color is applied to the shape based on Gradient direction, Gradient angle and gradient stop position. Please provide me the sample code to identify the text which is not visible based on color comparison.

Thanks,

Dhivya

Hi Dhivya,


I have tried to understand the requirements shared by you and have not been able to completely understand that. Can you please share the requirements in the form of sample presentation and snapshot highlighting your requirement. I will then be able to try investigating the requirement on my end and help you with possible sample code.

Many Thanks,

Hi,

I have attached the sample document for your reference. This document contains only one slide with three shapes. Shape 1 and 3 filltype is Gradient. The text in those shapes is not visible, because the shapes color and the text color is same. The text in Shape 2 is visible.So I need the sample code to validate the text in the shape is visible or not , if the text is not visible then I need to extract the text.

Thanks,
Dhivya

Hi Dhivya,


I have worked over your requirement and have created the sample code to serve the purpose for you. Please share, if I may help you further in this regard.

public static void testGradient()
{
String path = “C:\Presentations\”;
//Instantiate Prseetation class that represents the PPTX//Instantiate Prseetation class that represents the PPTX
using (Presentation pres = new Presentation(path + “Sample Presentation.pptx”))
{

//Get the first slide
ISlide sld = pres.Slides[0];

foreach (IShape shp in sld.Shapes)
{

FillType fill = shp.FillFormat.FillType;

if (fill == FillType.Gradient)
{
int count = shp.FillFormat.GradientFormat.GradientStops.Count;

Color txtColor=new Color();

if (shp is AutoShape)
{
txtColor = ((AutoShape)shp).TextFrame.Paragraphs[0].Portions[0].PortionFormat.FillFormat.SolidFillColor.Color;
}
for (int i = 0; i < shp.FillFormat.GradientFormat.GradientStops.Count; i++)
{
IGradientStop gStop = shp.FillFormat.GradientFormat.GradientStops[i];
Color stopColor = gStop.Color.Color;
if (stopColor == txtColor)
{
System.Console.WriteLine(“Gradient and text color matched”);
}
}

}

}

}
}

Many Thanks,