You can use the AccessWorkspaceFactory
instead. There are (at least) 3 ways to connect to a personal geodatabase. The simplest is probably the IWorkspaceFactory.OpenFromFile
method, e.g.:
//For example, pathToFile= "C:\\myData\\mypGDB.mdb".
static IWorkspace openFromFile_pGDB_Workspace(String pathToFile)throws Exception{
IWorkspaceFactory workspaceFactory = new AccessWorkspaceFactory();
return workspaceFactory.openFromFile(pathToFile, 0);
}
See How to connect to a geodatabase in the conceptual help for more information.
You might also look at the various IGPUtilities
helper methods if you want to deal with opening workspaces, feature classes, tables, etc. in a more generic way.