This is a migrated thread and some comments may be shown as answers.

Retrieving creation date of file

1 Answer 45 Views
Upload
This is a migrated thread and some comments may be shown as answers.
Daniel
Top achievements
Rank 1
Daniel asked on 24 Jul 2012, 02:30 AM
Hi, I need to know the original date of files.
After transfer, I have only their current date when they are copied.
Any ideas ?

Thanks

1 Answer, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 26 Jul 2012, 02:52 PM
Hi Daniel,

When you start to upload a file in the RadUpload control, the control has a reference to the FileInfo object describing the file. You can access it in the FileUploadStarting event handler through the e.SelectedFile.File property. However, you can get the CreationTime property of the FileInfo object only in a trusted application. Here you can find more information about the FileInfo class and its properties.

This basically means that in a trusted applicaiton you can get the CreationTime of the file that is going to be uploaded and save it somewhere on your client-side or pass it to the server side as described here.

All the best,
Tina Stancheva
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
Upload
Asked by
Daniel
Top achievements
Rank 1
Answers by
Tina Stancheva
Telerik team
Share this question
or