Hi,
I there any way to add shapes(not images) in specified tables cell.
Thx Ashish
//create PPT document
Presentation presentation = new Presentation();
//add new table of 3row and 5column to PPT
Double[] widths = new double[] { 120, 120, 120, 120, 120 };
Double[] heights = new double[] { 25, 25, 25 };
float tableX = presentation.SlideSize.Size.Width / 2 - 275;
ITable table = presentation.Slides[0].Shapes.AppendTable(tableX, 80, widths, heights);
for (int i = 0; i < heights.Length; i++)
{
for (int j = 0; j < widths.Length; j++)
{
//calculate the positions
int cellx = (int)(tableX + 53 + j * 120);
int celly = (int)(80 + 5 + i * (25 + 2 * i));
//draw shapes
table[j, i].Slide.Shapes.AppendShape(ShapeType.Triangle, new Rectangle(cellx, celly, 15, 15));
}
}
//save the document
presentation.SaveToFile("ShapesInTable.pptx", FileFormat.Pptx2010);