Initialize Method
Syntax
CWIMAQOval.Initialize Left, Top, Width, Height
Purpose
Sets all the properties of the oval with one method call.
Parameters
Left As Single
The leftmost x-coordinate of the oval.
Top As Single
The topmost y-coordinate of the oval.
Width As Single
The length of the horizontal axis of the oval.
Height As Single
The length of the vertical axis of the oval.
Example
Private Sub Run_Click()
Dim Oval1 As New CWIMAQOval
Dim Oval2 As New CWIMAQOval
'Initialize the first oval
Oval1.Initialize 55, 35, 125, 90
'Copy the properties from the first oval into the second oval
Oval1.CopyTo Oval2
'Move the first oval. This move does not affect the second oval
Oval1.Left = Oval1.Left + 70
Oval1.Top = Oval1.Top + 70
'Add the ovals to the viewer's regions collection.
CWIMAQViewer1.Regions.AddOval Oval1
CWIMAQViewer1.Regions.AddOval Oval2
End Sub