Hello,
I have a panel to which I add custom views. In addition, I keep a list to that I add the items for convenience. Now occasionally I need to reinitialize and remove everything.
Inside of the custom view cv_device there is a timer that just keeps fireing and the cv is still there. The list just gets longer even after the deviceremove.
Any way I can destroy the view?
Thanks
I have a panel to which I add custom views. In addition, I keep a list to that I add the items for convenience. Now occasionally I need to reinitialize and remove everything.
Remove:
Sub devicesremove()
For i = (devices_l.Size - 1) To 0 Step - 1
devices_l.Set(i, Null)
devices_l.RemoveAt(i)
Next
'devices_l.clear does not work either
devices.Panel.RemoveAllViews
devices.Panel.Height = 0
End Sub
Sub additem()
Dim item As cv_device
item.Initialize(something, something, something)
item.add(devices.panel, 0dip, devices.Panel.Height, devices.Panel.width, 100dip)
devices.Panel.Height = devices.Panel.Height + 100dip
devices_l.Add(item)
End Sub
Inside of the custom view cv_device there is a timer that just keeps fireing and the cv is still there. The list just gets longer even after the deviceremove.
Any way I can destroy the view?
Thanks