//Call Destroy method public void DestroyObjects() { if (Xfer != null && Xfer.Initialized) { Xfer.Destroy(); } if (Buffers != null && Buffers.Initialized) { Buffers.Destroy(); } if (Acquisition != null && Acquisition.Initialized) { Acquisition.Destroy(); } }
public Action Disconnect() { return(new Action(() => { if (Xfer != null) { Xfer.Destroy(); Xfer.Dispose(); } if (AcqDevice != null) { AcqDevice.Destroy(); AcqDevice.Dispose(); } if (Acquisition != null) { Acquisition.Destroy(); Acquisition.Dispose(); } if (Buffers != null) { Buffers.Destroy(); Buffers.Dispose(); } if (View != null) { View.Destroy(); View.Dispose(); } if (ServerLocation != null) { ServerLocation.Dispose(); } })); }
public void Disconnect( ) { try { if (Xfer != null) { Xfer.Destroy(); Xfer.Dispose(); } if (AcqDevice != null) { AcqDevice.Destroy(); AcqDevice.Dispose(); } if (Acquisition != null) { Acquisition.Destroy(); Acquisition.Dispose(); } if (Buffers != null) { Buffers.Destroy(); Buffers.Dispose(); } if (ServerLocation != null) { ServerLocation.Dispose(); } } catch (Exception) { } }