Exemple #1
0
        //0 = Not sure, trying initial download
        //1 = First download completed, HTML detecting, retrying

        public void CancelAsync()
        {
            if (_webClient != null)
            {
                _webClient.CancelAsync();
            }
        }
Exemple #2
0
        private void buttonCancel_Click(object sender, System.EventArgs e)
        {
            ListView.SelectedIndexCollection selectedIndices = listViewUrls.SelectedIndices;

            foreach (int index in selectedIndices)
            {
                WebClientEx client = webClients[index];

                if (client == null)
                {
                    continue;
                }

                if (!(client.IsBusy))
                {
                    continue;
                }

                client.CancelAsync();
            }
        }
Exemple #3
0
        //0 = Not sure, trying initial download
        //1 = First download completed, HTML detecting, retrying

        public void CancelAsync()
        {
            _webClient.CancelAsync();
        }