Solved

dbgrid & access 2000

Posted on 2000-03-24
2
201 Views
Last Modified: 2010-05-02
i am trying to read a database using a data control, the following error ocurs<<<Unrecognized database format <filename>. (Error 3343)>>>.

other forms are ok reading. the code i use is<<  Me.Data1.DatabaseName = (App.Path & "\NewMaster.mdb")

  Me.Data1.RecordSource = "select * from tblcustomers"

it sops at data1.refresh

i tried to repair database as suggested, but same problem. same data controls used in Access 97 dbase, works ok.

many thanks
0
Comment
Question by:sml41
2 Comments
 
LVL 1

Accepted Solution

by:
okcman earned 70 total points
ID: 2657559
http://www.microsoft.com/data/ado/adotechinfo/dao2ado.htm

here is a link about ADO and DA0 and access2000
 To add these references in Visual Basic:

Open a project.
From the Project menu select References…
From the list, select "Microsoft ActiveX Data Objects 2.1 Library."
From the list, select "Microsoft ADO Ext. 2.1 for DDL and Security."
From the list, select "Microsoft Jet and Replication Objects 2.1 Library."
Click OK.

they explained that the preferred way is  to ADO and do this:


Dim cnn As New ADODB.Connection
cnn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Nwind.mdb;"

if you are using both, they both have to be defined explicitly


hope this helps :)  


0
 

Author Comment

by:sml41
ID: 2737357
Yes many thanks, it works ok
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now