| 
       | 
        
       | Object Model Reference : Classes : L : Layer : Methods : Layer.CreateEllipse  | 
      
Function CreateEllipse(Left As Double, Top As Double, Right As Double, Bottom As Double, [StartAngle As Double = 90], [EndAngle As Double = 90], [Pie As Boolean = False]) As Shape
Member of Layer
The CreateEllipse method creates an ellipse shape at a specified location on a layer. The CreateEllipse method creates the ellipse by using the corners of its bounding box.
The following VBA example creates a rectangle with a red ellipse inside it, both at the lower-left corner of the page.
Sub Test()  | 
 Dim s As Shape  | 
 Dim lr As Layer  | 
 Set lr = ActiveLayer  | 
 ActiveDocument.DrawingOriginX = -ActivePage.SizeWidth / 2  | 
 ActiveDocument.DrawingOriginY = -ActivePage.SizeHeight / 2  | 
 lr.CreateRectangle 0, 0, 3, 2  | 
 Set s = lr.CreateEllipse(0, 0, 3, 2)  | 
 s.Fill.UniformColor.RGBAssign 255, 0, 0 'Red  | 
End Sub  | 
| 
       | 
        
       | 
		      
		          
		             | 
      
Copyright 2013 Corel Corporation. All rights reserved.