Could not use ''; file already in use."

System.Data.OleDb.OleDbException occurred
  ErrorCode=-2147467259
  Message=”Could not use ”; file already in use.”
  Source=”Microsoft JET Database Engine”

Access, lock files, and Visual Source Safe – an accident waiting to happen! I got the above error, after my code had been fine for weeks. Googling turned up permissions on the folder with the Access database, and closing secondary applications. The solution in the end turned out to be that the .ldb file had come under source control. Removing it from this, and deleting the fle resolved the issue.



Discussion has just started! Join in...

  1. farvish says:

    Nice article. This error may come due to corruption in database. In this situation you can use compact and repair option or access repair utility which can fix the error and repair database

Leave a Reply

Your email address will not be published. Required fields are marked *

Comment

You may use these tags : <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>