I am uploading a document in SharePoint document library and would like to capture original creation date of the document. Can anyone let me know about this?

For Eg: If a document is created on 1st of July and I am uploading it on 15th of July. Then I would like to capture the 1st July in some column. I can create a new column in the library to add the date.

Any help is appreciated.

1 Answer 1


One option is to use SPFile.Properties to read the properties of the uploaded file. In the aforementioned link the example outputs a property vti_timecreated. You would have to create an event receiver to check when the file is uploaded to library and get the created value and put it into a new column. Alternatively, you can also create a timer job to do this to run say, every hour, and update the library.

  • This only gives the item time creation instead of file creation.
    – Ankit
    Oct 9, 2015 at 5:19
  • @Ankit: The documentation for vti_timecreated says - its the time, including date, at which the current object was created. I would assume that it would be the creation of the file, though I haven't tried it so cannot verify it. Also refer to this question which says that - Not possible without code. I would say that your best chance in getting your value would be somewhere in SPFile
    – Naveen
    Oct 9, 2015 at 5:57
  • This works when you are uploading the document from same server. But doesn't working from client machine. I tried this earlier as well.
    – Ankit
    Oct 12, 2015 at 9:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.