create an DAO Access file in Excel VBA <p>I am unable to create a file using following commands, could anyone help me in this regard. The error it says is invalid argument. I got office 2010.</p> <p>My ref is :MS office 14.0 ACCESS DATABASE OBJECT LIBRARY</p> <pre><code>Sub DBcreate() Dim DB As DAO.Database Dim RS As DAO.Recordset Set DB = DAO.Workspaces(0).CreateDatabase("D:\tblImport11.accdb", DB_LANG_GENERAL) DB.Close 'Set RS = Nothing Set DB = Nothing End Sub </code></pre> <p>i also tried:</p> <pre><code>Set DB = DBEngine.CreateDatabase("D:\tblImport11.accdb", DB_LANG_GENERAL) </code></pre> <p>This also gives same error</p>