Should be fairly simple:
WebClient client = new WebClient();
client.DownloadProgressChanged += client_DownloadProgressChanged;
client.DownloadFileCompleted += client_DownloadFileCompleted;
foreach (string url in File.ReadLines(@"C:\Path\To\Your\TextFile.txt"))
{
if (!Uri.TryCreate(url, UriKind.Absolute, out var uri))
{
Console.WriteLine("Invalid URL: '{0}'", url);
continue;
}
string fileName = uri.Segments.Last();
string filePath = System.IO.Path.Combine(@"C:\Program Files\OpenVPN\config", fileName);
if (System.IO.File.Exists(filePath)) System.IO.File.Delete(filePath);
Console.WriteLine("Download '{0}' to '{1}'...", uri, filePath);
client.DownloadFile(uri, filePath);
}
Just put each link to download on a new line in the text file.