Jeremy Toves
itsame2000 at sbcglobal.net
Mon Sep 11 15:00:15 CDT 2006
I hit a snag with a process I'm putting together. I'm trying to use the OpenDatabase method in an Access 2000 database to open a second Access 2000 database so that I can enumerate indices. I want to delete indices and reindex on demand from the first database. I'm getting an error that the database is an unrecognized format. I can open the 2nd database without problem if I go to it directly. Here is the code I'm using. Ideas? Has anyone done this before? Thanks, Jeremy Sub TestThis() Dim wrkJet As DAO.Workspace Dim db As DAO.Database Dim sDB As String sDB = "C:\Test\BackEnd.mdb" Set wrkJet = CreateWorkspace("wrkSpace", "admin", "", dbUseJet) Set db = OpenDatabase(sDB, True) Set db = Nothing Set wrkject = Nothing End Sub