how do I access an access db (mdb) from vb 
Author Message
 how do I access an access db (mdb) from vb

when I attempt to use vb.net to access my db, i first add the reference to
the project (for both jet10 and dao3.6--either would be fine) and the system
asks if it's ok to package the dlls for net, I agree and then I can see them
in the solution explorer but vb wont allow me to create ad dbEngine object,
table, etc. like i did in vb6--what am I doing wrong (or not doing)
thanks,
Jeff Fischman


Mon, 05 Apr 2004 03:43:47 GMT  
 how do I access an access db (mdb) from vb
Jeff,
  I did try to do it with VB.NET, it seems to work perfectly fine.
  I didn't try to run the program ofcourse. Is it throwing an error when you
are running?

OK, here is what I did:

1) I right-clicked on references of my project and chose 'Add Reference'
2) Selected the COM tab and checked 'Microsoft DAOx library'
3) It asked me whether it can create a type library for me, I said Yes
4) I saw the 'DAO' on the reference list
5) I said 'Import DAO' in my code window
6) I started using it like any other library

I hope this helps you.

Eswar


Quote:
> when I attempt to use vb.net to access my db, i first add the reference to
> the project (for both jet10 and dao3.6--either would be fine) and the
system
> asks if it's ok to package the dlls for net, I agree and then I can see
them
> in the solution explorer but vb wont allow me to create ad dbEngine
object,
> table, etc. like i did in vb6--what am I doing wrong (or not doing)
> thanks,
> Jeff Fischman



Thu, 08 Apr 2004 07:39:21 GMT  
 how do I access an access db (mdb) from vb
I haven't tried this myself but I would think that you would use the
Microsoft.Jet.OLEDB.4.0 provider under ADO.NET to connect to your access
database.

Regards


Quote:
> Jeff,
>   I did try to do it with VB.NET, it seems to work perfectly fine.
>   I didn't try to run the program ofcourse. Is it throwing an error when
you
> are running?

> OK, here is what I did:

> 1) I right-clicked on references of my project and chose 'Add Reference'
> 2) Selected the COM tab and checked 'Microsoft DAOx library'
> 3) It asked me whether it can create a type library for me, I said Yes
> 4) I saw the 'DAO' on the reference list
> 5) I said 'Import DAO' in my code window
> 6) I started using it like any other library

> I hope this helps you.

> Eswar



> > when I attempt to use vb.net to access my db, i first add the reference
to
> > the project (for both jet10 and dao3.6--either would be fine) and the
> system
> > asks if it's ok to package the dlls for net, I agree and then I can see
> them
> > in the solution explorer but vb wont allow me to create ad dbEngine
> object,
> > table, etc. like i did in vb6--what am I doing wrong (or not doing)
> > thanks,
> > Jeff Fischman



Fri, 09 Apr 2004 18:54:07 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Converting Access 2.0 DB to Access 97 DB in VB code

2. Use VB 6 with an Access DB (MDB)

3. Exporting Access MDB to DBF - DB via VB?

4. TransferDatabase method from Access 95 mdb to Access 97 mdb

5. Access 2 and Access 7 MDB's from VB

6. VB 4.0 can NOT access Access 7.0 .MDB

7. Using VB to access MS Access (mdb file) in remote host

8. Convert Access 97 db to Access 2000 db in VB6

9. Attaching Access Db files to Access DB

10. script accessing mdb DB

11. Accessing encrypted data in Access 2000 DB via VB

12. Accessing an MS ACCESS DB online with VB

 

 
Powered by phpBB® Forum Software