FreeformBuilder.ConvertToShape Method
Creates a shape that has the geometric characteristics of the specified FreeformBuilder object. Returns a CanvasShapes object that represents the new shape.
Namespace: Microsoft.Office.Interop.PowerPoint
Assembly: Microsoft.Office.Interop.PowerPoint (in Microsoft.Office.Interop.PowerPoint.dll)
Syntax
'Declaration
Function ConvertToShape As Shape
'Usage
Dim instance As FreeformBuilder
Dim returnValue As Shape
returnValue = instance.ConvertToShape()
Shape ConvertToShape()
Return Value
Type: Microsoft.Office.Interop.PowerPoint.Shape
Shape
Remarks
You must apply the AddNodes(MsoSegmentType, MsoEditingType, Single, Single, Single, Single, Single, Single) method to a FreeformBuilder object at least once before you use the ConvertToShape method.
Examples
This example adds a freeform with five vertices to the first slide in the active presentation.
Set myDocument = ActivePresentation.Slides(1)
With myDocument.Shapes.BuildFreeform(msoEditingCorner, 360, 200)
.AddNodes msoSegmentCurve, _
msoEditingCorner, 380, 230, 400, 250, 450, 300
.AddNodes msoSegmentCurve, msoEditingAuto, 480, 200
.AddNodes msoSegmentLine, msoEditingAuto, 480, 400
.AddNodes msoSegmentLine, msoEditingAuto, 360, 200
.ConvertToShapeEnd With