Hello everyone, how can I save the stream of files stored in a folder in an array? This is my code:
string ruta = @"C:\";
foreach (string s in Directory.GetFiles(ruta))
{
//Obtengo en (s) todos los archivos almacenado en la carpeta
FileStream filestr= File.OpenRead(s);
}
I save the stream of the file s in the filestr variable, but it will change as I go through the foreach, there is some way to save the stream of each file, in an arrangement to later use it.