Blacker.Scraper.Helpers.WebHelper.DownloadImage C# (CSharp) Method

DownloadImage() public static method

public static DownloadImage ( string imageUrl, string fileName ) : void
imageUrl string
fileName string
return void
        public static void DownloadImage(string imageUrl, string fileName)
        {
            if (imageUrl == null)
                throw new ArgumentNullException("imageUrl");
            if (fileName == null)
                throw new ArgumentNullException("fileName");

            using (var image = GetImageFromUrl(imageUrl))
            {
                image.Save(fileName);
            }
        }