Oct 5, 2011 at 5:39 PM
Edited Oct 5, 2011 at 8:11 PM
i have formatted the code below
// Remove the directory part of the filename just prior to unzipping
// extracting only .xyz files
zip.ToList().Where(s => !s.IsDirectory && Path.GetExtension(s.FileName) == ".xyz").ToList().
entry.FileName = Path.GetFileName(entry.FileName);
entry.CreationTime = dtUploadTime;
entry.Comment = sUser;
Not withstanding the folks all around the globe, I have a requirement where the user uploads a zip file and that information needs to be shown on the webpage. When the user uploads the zip file I unzip it to a folder and delete the original zip file. Lets
say the contents of the zip file are 1.xyz and 2.xyz and is being uploaded by Aunt Molly.
In the aforementioned code I have set the comment attribute as sUser. (sUser = "Aunt Molly';)
While displaying the results in the UI, one would like to display that Aunt Molly uploaded 1.xyz and 2.xyz. I am getting the file information using the following code
FileInfo fiFiles = new DirectoryInfo(sFileUploadLocation).GetFiles("*.xyz");
Is there a way to retrieve "Aunt Molly"s name ?
PS: I modified the code to the following
foreach (var fileInfo in fiFiles)
FileVersionInfo fileVersInfo = FileVersionInfo.GetVersionInfo(fileInfo.FullName);
String sComments = fileVersInfo.Comments;
the comments is always null.
when we set
entry.Comment = "Aunt Molly';
what exactly is being set ?
let me know if you need anything else ?