WebClient类数据下载

        public void GetFile(string url, string filename)
        {
            WebClient wc = new WebClient();
            MemoryStream ms = new MemoryStream(wc.DownloadData(url));
            Image img = Image.FromStream(ms);
            img.Save(picpath + filename);
        }

你可能感兴趣的:(WebClient类数据下载)