c# - How do I get a list of files from a web directory? -


How do I get a list of files from a web directory? If I use the Web Directory URL then the Internet browser lists all the files in that directory. Now I just want to get that list in C # and download them in BITS (Background Intelligent Transfer Service).

About the "Get that list in C #" section:

  foreach (string.php file name in Directory.GetFiles (Server MapPath ("/"), "* .jpg", SearchOption.All Directories) {Response.Write (String.Format ("{0} & Gt; ", Server.HtmlEncode (filename));}  

Comments

Popular posts from this blog

asp.net - Javascript/DOM Why is does my form not support submit()? -

sockets - Delphi: TTcpServer, connection reset when reading -

javascript - Classic ASP "ExecuteGlobal" statement acting differently on two servers -