title: Do the DSOFile functions only apply to the non-binary Excel Document types?
body: <p>Using Windows 10 (Build 1903 if that's relevant?) and 64bit Office 365 (probably relevant?) I've implemented a <a href="https://www.xltrail.com/blog/auto-export-vba-commit-hook" rel="nofollow noreferrer">system that allows me to version control Excel VBA code</a>.</p>
  
  <p>I'm using the <code>Workbook_BeforeSave</code> method to check whether the current file is saved or not, and if it is saved, where it is saved to.</p>
  
  <p>This works fine and will prompt the user as to whether they want to update the code contained within. I then thought that maybe I should in fact check if the code "needs" to be updated prior to prompting the user.</p>
  
  <p>First off, I found the following question/solution: <a href="https://stackoverflow.com/q/7477269/572634">Using VBA to read the metadata or file properties of files in a SharePoint doc library</a></p>
  
  <p>which I couldn't use without DSOFile.dll that I was able to install from here:</p>
  
  <p><a href="https://www.microsoft.com/en-us/download/details.aspx?id=8422" rel="nofollow noreferrer">https://www.microsoft.com/en-us/download/details.aspx?id=8422</a></p>
  
  <p>Here follows the code I have which doesn't work:</p>
  
  <pre class="lang-vb prettyprint-override"><code>Private Function CheckTemplateIsNewerThanCurrentFile(ByVal templatePath As String) As Boolean
      Dim templateName As String
      Dim fso As New FileSystemObject
      templateName = ActiveWorkbook.CustomDocumentProperties("TemplateName").Value
      If fso.FileExists(templatePath &amp; "\" &amp; LocalTemplateName) Then
          Dim objDSO As New DSOFile.OleDocumentProperties
          objDSO.Open templatePath &amp; "\" &amp; LocalTemplateName, True, dsoOptionDefault
          If Not objDSO.CustomProperties("LastCommitDate") = ActiveDocument.CustomDocumentProperties("LastCommitDate").Value Then
              CheckTemplateIsNewerThanCurrentFile = False
          Else
              CheckTemplateIsNewerThanCurrentFile = True
              TemplateLastCommitDate = objDSO.CustomProperties.Item("LastCommitDate")
          End If
      End If
  End Function
  </code></pre>
  
  <p>And here (highlighted) is the error I receive trying to run the method above on an .xlsb file:</p>
  
  <p><a href="https://i.imgur.com/Uhv1vZc.png" rel="nofollow noreferrer"><img src="https://i.imgur.com/Uhv1vZc.png" alt="Error message"></a></p>
  
  <p>(FWIW: the reason for use of the .xlsb format is because we're working with 500K+ rows of data in the process we're carrying out. Yes, I know Excel is ABSOLUTELY NOT the tool for this but we're lumbered with it now)</p>
  
  <p>I know I could have already tried changing the file format to .xlsm but because this file is version controlled that is a pain to do if the method is still likely to fail.</p>
  
  <p>Thanks in advance,</p>
  
  <p>Alex.</p>