When I use:
WebClient web = new WebClient();
web.DownloadProgressChanged += new DownloadProgressChangedEventHandler(ProgressChangedWeb);
web.DownloadFileAsync(new Uri("http://www.website.com/Webs.exe"),
Environment.SpecialFolder.Desktop + @"\Webs.exe");
…Nothing downloads.
But if i change it to”
WebClient web = new WebClient();
web.DownloadProgressChanged += new DownloadProgressChangedEventHandler(ProgressChangedWeb);
web.DownloadFileAsync(new Uri("http://www.website.com/Webs.exe"),
Environment.SpecialFolder.Desktop + "Webs.exe");
Then It downloads, but I get a file named “desktopWebs.exe”. So How can I save a file to the desktop?
Thanks
What you want is this…
Otherwise you are just tacking on the word desktop instead of the actual path.