title: SQL Compact Edition 3.5 - Access to the database file is not allowed
body: <p>I developed an application (100% local, no access to servers) using <a href="http://en.wikipedia.org/wiki/SQL_Server_Compact" rel="noreferrer">SQL Server Compact</a> 3.5, and it works fine on my computer. However, when I deployed it on another computer, it shows this error:</p>
  
  <pre><code>Access to the database file is not allowed. [ File name = data\BDApepucCE.sdf ]
  </code></pre>
  
  <p>I deployed on a Windows XP computer. It shows this error whenever I try to write on the database, however, it works when I read.</p>
  
  <p>I did a test on a Windows 7 computer, and it worked 100%, except when the file was accessed through the homegroup (that is, local network), on which it failed on both read/write.</p>
  
  <p>Platform: Windows 7, Visual Studio 2010, and <a href="http://msdn.microsoft.com/en-us/library/cc656912%28v=vs.110%29.aspx" rel="noreferrer">.NET 4 Client Profile</a></p>