A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

From VB .Net, how obtain ref to Access project?



 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old February 7th, 2005, 08:09 PM
Ed White
external usenet poster
 
Posts: n/a
Default From VB .Net, how obtain ref to Access project?

From VB .Net, using either DAO or ADOX (or whatever else is available), how
can I obtain a reference to a database file created in Access? For example,
I tried the following:

Dim AccessApp As New Microsoft.Office.Interop.Access.Application
AccessApp.OpenCurrentDatabase("C:\Documents and Settings\...\filename.mdb")
Dim cat As ADOX.Catalog
cat.ActiveConnection = AccessApp.CurrentProject.Connection

The last statement gives me a "Object reference not set to an instance of an
object" error.
--
Ed
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Access Error Message when opening database eah General Discussion 3 January 26th, 2005 10:04 AM
Using Access 2000 with VB .Net Roger Stenson New Users 0 January 13th, 2005 05:56 PM
Access and VB HS1 General Discussion 2 September 9th, 2004 09:01 PM
Signing a VBA mde/mdb Access 2003 John Buckett General Discussion 3 July 3rd, 2004 09:14 PM


All times are GMT +1. The time now is 06:14 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.