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#

This file contains invisible Unicode characters!

This file contains invisible Unicode characters that may be processed differently from what appears below. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to reveal hidden characters.

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)
{
}
}
}
}