Add_ExternalLines example
Example for Add_ExternalLines method
Private Sub Form1_Load(ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles MyBase.Load
cAvax1.StartAvax()
End Sub
Private Sub Form1_FormClosed(ByVal eventSender As System.Object, ByVal eventArgs As System.Windows.Forms.FormClosedEventArgs) Handles Me.FormClosed
cAvax1.EndAvax()
End Sub
Private Sub CAvax1_SetExternalLines(ByVal Sender As Object, ByVal e As Avax.cAvax.SetExternalLinesEventArgs) Handles cAvax1.SetExternalLines
Select Case e.sName
Case "My rectangle"
Dim x1(4) As Single
Dim y1(4) As Single
Dim z1(4) As Single
Dim x2(4) As Single
Dim y2(4) As Single
Dim z2(4) As Single
x1(1) = 0 : y1(1) = 0 : x2(1) = 0 : y2(1) = 10
x1(2) = 0 : y1(2) = 10 : x2(2) = 10 : y2(2) = 10
x1(3) = 10 : y1(3) = 10 : x2(3) = 10 : y2(3) = 0
x1(4) = 10 : y1(4) = 0 : x2(4) = 0 : y2(4) = 0
e.x1 = x1
e.y1 = y1
e.z1 = z1
e.x2 = x2
e.y2 = y2
e.z2 = z2
End Select
End Sub
Private Sub Command1_Click(ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles Command1.Click
Dim sName As String
Dim vItemProperties As Object
Dim iClr As Short
Dim iWidth As Short
Dim iStyle As Short
Dim iLayer As Short
Dim Answer As Integer
sName = "My rectangle"
iClr = 1
iWidth = 2
Answer = cAvax1.Add_ExternalLines(sName, vItemProperties, iClr, iWidth, iStyle, iLayer)
End Sub