public void CloseChannel() { ICommunicationObject channel = m_channel as ICommunicationObject; if (channel != null && channel.State == CommunicationState.Opened) { channel.Abort(); } }