Visual Basic + Microsoft Access

Zenax

Active Member
Messages
1,377
Reaction score
4
Points
38
Hey i was wondering if any of you have any experience with Visual Basic and Microsoft Access.

I am trying to create a database driven application from Visual Basic using a MS Access DB. Except I get an error.

Error Code 3343: This is an unrecognized database format.

Any ideas on how to fix this?

--
Zenax
 

Micro

Retired staff <i> (11-12-2008)</I>
Messages
1,301
Reaction score
0
Points
36
Incorrect Versions / File Corruption is the cause of this error.. Hmm.. Dont know otherwise :) Also, which version of VB are you using?
 

Zenax

Active Member
Messages
1,377
Reaction score
4
Points
38
I am using Visual Basic 6.0 with Microsoft Access 2000

Looking up on the internet I fount this code:

Code:
Option Explicit
Private daoDB36 As Database
Private rs As DAO.Recordset
Dim sPath As String

Private Sub Form_Load()
sPath = _
"path of database here"
Set daoDB36 = DBEngine(0).OpenDatabase(sPath)
Set rs = daoDB36.OpenRecordset("Customers")
Set Data1.Recordset = rs
End Sub

This code was the microsoft website, but it does not work.
Website: http://support.microsoft.com/kb/238401

So any ideas people?

--
Zenax

EDIT: it works on my college version of Visual Basic but not at home, and I swear they are the same version. Perhaps cuz at college I am using MS Access 2003 where Im using 2000 at home

EDIT 2: I have tried reparing/compressing the DB at home but to no avail!
 
Last edited:
Top