Private Sub Command1_Click() CreateDatabase "c:\123.mdb" End Sub
Public Sub CreateDatabase(ByVal sDatabaseFile As String) Dim cat Set cat = CreateObject("ADOX.Catalog") cat.Create "Provider=Microsoft.Jet.OLEDB.4.0;data source=" & sDatabaseFile Set cat = Nothing End Sub