public void Abort (object sender, EventArgs args) { WebConnection other = ((HttpWebRequest) sender).WebConnection; if (other == null) other = Connection; other.Abort (sender, args); } }