Hello,
Actually, i have a website url where these files are stored. Example:
http://www.mywebsite.com/files/file.txt
http://www.mywebsite.com/files/image1.gif
http://www.mywebsite.com/files/logo.jpg
http://www.mywebsite.com/files/letter.doc
http://www.mywebsite.com/files/dll/barcode.dll
http://www.mywebsite.com/files/dll/MyLib.dll
http://www.mywebsite.com/files/dll/Common.dll
http://www.mywebsite.com/files/exe/MyApp.exe
etc...
So, my target is to build a small Device Application (Windows CE) in order to update these files on the device itself everytime the user clicked Update button.
So I would like to download the content of the main folder http://www.mywebsite.com/files/ as is (e.g. with all files & sub-folders) on the device.
Please, can anyone help me to know how to connect to the URL and download the list of files ?
I really appreciate if you can give me a sample code
Paul
Loading
SenthilkumarPosted Mar 30, 2012, 11:52 PM
References:
http://www.etechplanet.com/blog/downloading-file-using-aspnet-and-c.aspx
http://www.west-wind.com/weblog/posts/2007/May/21/Downloading-a-File-with-a-Save-As-Dialog-in-ASPNET
Bryian TanPosted Mar 30, 2012, 8:43 PM
Have you try to use WebRequest and WebResponse Classes ? Here are few examples.
http://www.codeguru.com/columns/dotnettips/article.php/c7005/Downloading-Files-with-the-WebRequest-and-WebResponse-Classes.htm
http://code.msdn.microsoft.com/CSASPNETRemoteUploadAndDown-a80b7cb5