Click here to Skip to main content
15,891,689 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hi all my program after selecting the folder will be crashed

What I have tried:

 WebClient client = new WebClient();
            folderBrowserDialog1.ShowDialog();
            
                client.DownloadFileAsync(new
Uri("url"),folderBrowserDialog1.SelectedPath);

                client.DownloadProgressChanged += Changed;
                client.DownloadFileCompleted += new AsyncCompletedEventHandler(Completed);
Posted
Updated 8-Nov-19 2:59am

1 solution

Uri("url")
will not work, you need to use a real address.

Also see example here: How to download a webfile with C# and show download progress synchronously and asynchronously | Our Code World[^]
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900