title: How to Close Sqlite Connection without explicitly calling Close Method using .NET
body: <p>I am creating desktop application in winform that will use Sqlite Database.</p>
  
  <p>So I created Sqlite Helper class that uses <code>System.Data.SQLite</code> and each method of that Helper class opens and closes connection.</p>
  
  <p>But now I also added ability to attach additional databases but after Connection is Closed, all attached databases gets lost.</p>
  
  <p>To correct this I modified the class so that the connection is opened in constructor and remains open.</p>
  
  <p>After the application ends, I want that connection to close without explicitly calling the Close method.</p>
  
  <p>Any suggestions how to do that?</p>