title: Get "Correct" Created field for version of file in Sharepoint
body: <p>I've just encountered what appears to be a really annoying "feature" in SharePoint (it may be by design, but the scope of that is probably beyond this question).</p>
  
  <p>I am helping to develop an application that retrieves files and their version history for specific files stored on SharePoint. This information is uploaded to a data warehouse, one of the critical fields we need to capture is the time the file version was originally uploaded (i.e. created) onto SharePoint.</p>
  
  <p>Initially this appeared to be fairly straight forward, using the (SharePoint WebServices) version service (versions.asmx) we called:</p>
  
  <pre><code>SPVersion.GetVersions(fullpath);
  </code></pre>
  
  <p>Which returns us an XML result similar to below (including a field called "created"):</p>
  
  <pre>
  &lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"&gt;
    &lt;soap:Body&gt;
      &lt;GetVersionsResponse xmlns="http://schemas.microsoft.com/sharepoint/soap/"&gt;
        &lt;GetVersionsResult&gt;
          &lt;results xmlns="http://schemas.microsoft.com/sharepoint/soap/"&gt;
            &lt;list id="{guid}"/&gt;
            &lt;versioning enabled="1"/&gt;
            &lt;settings url="http://SITE/_layouts/LstSetng.aspx?List={guid}"/&gt;
            &lt;result version="@6.0" url="http://SITE/PATH/FILENAME" created="12/8/2009 11:58 AM" createdBy="DOMAIN\USER" size="149504" comments=""/&gt;
            &lt;result version="1.0" url="http://SITE/_vti_history/id/PATH/FILENAME" created="12/7/2009 4:10 PM" createdBy="DOMAIN\USER" size="148992" comments=""/&gt;
            &lt;result version="2.0" url="http://SITE/_vti_history/id/PATH/FILENAME" created="12/8/2009 11:32 AM" createdBy="DOMAIN\USER" size="149504" comments=""/&gt;
            &lt;result version="3.0" url="http://SITE/_vti_history/id/PATH/FILENAME" created="12/8/2009 11:45 AM" createdBy="DOMAIN\USER" size="149504" comments=""/&gt;
            &lt;result version="4.0" url="http://SITE/_vti_history/id/PATH/FILENAME" created="12/8/2009 11:49 AM" createdBy="DOMAIN\USER" size="149504" comments=""/&gt;
            &lt;result version="5.0" url="http://SITE/_vti_history/id/PATH/FILENAME" created="12/8/2009 11:58 AM" createdBy="DOMAIN\USER" size="149504" comments=""/&gt;
          &lt;/results&gt;
        &lt;/GetVersionsResult&gt;
      &lt;/GetVersionsResponse&gt;
    &lt;/soap:Body&gt;
  &lt;/soap:Envelope&gt;
  
  
  </pre>
  
  <p>All well and good, until you look closely at the created field - versions 5 &amp; 6 have exactly the same created date. Further investigation revealed to me that ALL versions of the document have a created datetime that matches the actual created datetime for the next version of the document. I.E. When I check SharePoint and look at the version history I can see version 2 was actually created at 16:10, the time that is showing above for version 1.</p>
  
  <p>I am assuming that the created field is NOT actually the created field, but is a modified field that takes into account when the file was modified and made an "older" version.</p>
  
  <p>Has anyone encountered this problem and found a reliable way to get the versions service to return the actual time of creation of the file, or - using the information above - is there a reliable mechanism to get the time on the file? </p>
  
  <p>Note that we cannot use the SharePoint API / DLL's for this project.</p>
  
  <p>Thanks
  Chris</p>