Opening an access application

ram_Sathish

New Member
Joined
Jun 12, 2006
Messages
15
Hi All,

I tried opening an access application through creating an object of the access application in VB 6.0 by giving the following codes.

set obj =createobject ("access.application")
set obj1=obj.openaccessproject("Path of the file")

i am unable to open an access application.
please help me out.


thanks
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
Ram, If you are using ADO to connect you will need to reference the ADO 2.x library and use this syntax:
Code:
Dim adoconnection As ADODB.Connection
Dim rs As ADODB.Recordset
Dim connectstring As String

Set adoconnection = New ADODB.Connection
Set rs = New ADODB.Recordset

connectstring = "provider=microsoft.jet.oledb.3.51;" _
& "data source=YourDB_Path"

adoconnection.Open connectstring
If you are using DAO you will need to reference the DAO 3.6 library and use syntax like this:
Code:
Dim db as dao.database 
set db = dbengine.workspaces(0).opendatabase("YourDB_path")
Denis
 
Upvote 0

Forum statistics

Threads
1,214,413
Messages
6,119,372
Members
448,888
Latest member
Arle8907

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top