title: How can a blank MS Access database be created using VBA?
body: <p>I'm a total noob trying to create a blank MS Access database using VBA in Excel. I want to name the new database "tblImport". This is the code I´m using:</p>
  
  <pre><code>   Sub makedb()
     Dim accessApp As Access.Application
     Set accessApp = New Access.Application
     accessApp.DBEngine.CreateDatabase "C:\tblImport.accdb", dbLangGenera
     accessApp.Quit
     Set accessApp = Nothing
     End Sub
  </code></pre>
  
  <p>I get the following error message:</p>
  
  <p>"Run Time Error 3001: Application Defined or Object Defined Error"</p>
  
  <p>What can I do?</p>