private static bool IsConnectionActive() { if (ListenForDataThread != null) return ListenForDataThread.IsAlive; else return false; }