-
May 12th, 2014, 09:04 AM
#1
Thread Starter
New Member
Cannot Find Installable ISAM Exception
The following code generates the exception on o_DBEngine.CreateDatabase:
Public Sub New()
Dim o_DBEngine As New DBEngine
Dim o_Database As DAO.Database
Dim o_WorkSpace As DAO.Workspace
Dim o_TableDef As New TableDef
' Create and open the main database
If (Dir(Application.StartupPath + "\" + modUtilities.DATABASE_NAME) = "") Then
Try
InitializeComponent()
o_DBEngine.CreateDatabase(modUtilities.DATABASE_NAME, "General") <-------- EXCEPTION ON THIS LINE
o_WorkSpace = o_DBEngine.CreateWorkspace(MAINWS, "admin", "")
o_Database = o_DBEngine.Workspaces(MAINWS).OpenDatabase(modUtilities.DATABASE_NAME)
o_TableDef.Name = "Person"
o_TableDef.CreateField("PersonID", DAO.DataTypeEnum.dbLong)
o_TableDef.Fields("PersonID").Attributes = DAO.FieldAttributeEnum.dbAutoIncrField
o_TableDef.CreateField("FirstName", DAO.DataTypeEnum.dbText, 255)
o_TableDef.CreateField("LastName", DAO.DataTypeEnum.dbText, 255)
Catch o_Exception As Exception
MsgBox("Exception: " + o_Exception.Message)
End Try
End If
End Sub
Has anybody over come this? I have re-installed MDAC 2.8 to no avail. I'd really appreciate some help. Thank you.
-
May 12th, 2014, 09:14 AM
#2
Re: Cannot Find Installable ISAM Exception
I think you use incorrect parameters in CreateDatabase:
http://msdn.microsoft.com/en-us/libr...ffice.15).aspx
But I never used DAO, it's obsolete for a long time
-
May 12th, 2014, 09:22 AM
#3
Re: Cannot Find Installable ISAM Exception
i remember this error coming from some broken installation. There is a MS tool somewhere out there that checks all DAO components and compatibility. I remember beeing able to resolve this error some 10 years ago using this tool.
-
May 12th, 2014, 09:48 AM
#4
Re: Cannot Find Installable ISAM Exception
If I was you, I would start changing to a more current Database system. Sorry I can't help you with this.
More important than the will to succeed, is the will to prepare for success.
Please rate the posts, your comments are the fuel to keep helping people
-
May 14th, 2014, 12:14 AM
#5
Re: Cannot Find Installable ISAM Exception
It would be more informative if you could name the exception you're getting, but I suspect that you're running this on a 64-bit machine. DAO is 32-bit so you must change the Target CPU setting. In VS click Project > Project Name Properties and on the Compile tab change the Target CPU to x86.
-
May 14th, 2014, 02:52 AM
#6
Re: Cannot Find Installable ISAM Exception
I would check that the database was saved in the correct file format for the version of the DB.Engine you are using.
when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
https://get.cryptobrowser.site/30/4111672
-
May 14th, 2014, 03:35 AM
#7
Re: Cannot Find Installable ISAM Exception
Originally Posted by Nightwalker83
I would check that the database was saved in the correct file format for the version of the DB.Engine you are using.
He gets the exception when he tries to create the database. So the database doesn't exist yet.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|