// Create a new shape
Aspose.Cells.Drawing.Shape polygonShape = xlWorkSheet.Shapes.AddAutoShape(Aspose.Cells.Drawing.AutoShapeType.RoundedRectangularCallout, 0, 0, 0, 0, 0, 0);
polygonShape.Y = 200; //Shape Top properties
polygonShape.X = 500; //Shape Left properties
polygonShape.Width = 200; // Shape Width
polygonShape.Height = 100; // Shape Height
image.png (11.7 KB)
@pajalit911,
We have noted your requirements and issues you mentioned. We will check on how to directly modify individual connection points or the vertices of the shapes in code via Aspose.Cells APIs. We may enhance the APIs and provide example code snippets to cope with your issues and accomplish your tasks.
We have opened the following new ticket(s) in our internal issue tracking system and will deliver code snippets or fixes according to the terms mentioned in Free Support Policies.
Issue ID(s): CELLSNET-56854
Once we have an update on it, we will let you know.
@pajalit911
The RoundedRectangularCallout type of shape usually has three adjustment points. The following sample code shows how to adjust it.
// Create a new workbook
Workbook workbook = new Workbook();
Worksheet sheet = workbook.Worksheets[0];
// Add a button to the worksheet
Shape polygonShape = sheet.Shapes.AddAutoShape(AutoShapeType.RoundedRectangularCallout, 0, 0, 0, 0, 0, 0);
polygonShape.Y = 200; //Shape Top properties
polygonShape.X = 500; //Shape Left properties
polygonShape.Width = 200; // Shape Width
polygonShape.Height = 100; // Shape Height
ShapeGuideCollection shapeGuides = polygonShape.Geometry.ShapeAdjustValues;
shapeGuides.Add("adj1", 1.02167d); //The distance between the tip point and the center point, with negative values on the left and positive values on the right. Its value is usually the ratio of the half-width.
shapeGuides.Add("adj2", -0.295d); //The distance between the tip point and the center point, negative for upwards and positive for downwards. Its value is usually a ratio of the half-height.
shapeGuides.Add("adj3", 0.16667d); //Usually the default value
I hope it helps you.
If you encounter any problems, you can always contact us.