You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
655 B
C#

using System;
using System.Net;
namespace ZJ_BYD.Untils
{
public class FileHelper
{
/// <summary>
        /// 下载文件
        /// </summary>
        /// <param name="url">下载文件地址</param>
/// <param name="savePath">保存路径</param>
        public static void DownloadFile(string url,string savePath)
{
WebClient mywebclient = new WebClient();
try
{
mywebclient.DownloadFile(url,savePath);
}
catch (Exception ex)
{
}
}
}
}