Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dynamicly Setting Data Environment Connection Objects.

Status
Not open for further replies.

SQLwannabe

Programmer
May 3, 2001
16
0
0
US
I'm using Data Environment Connection Objects for use with my reports in my project. I cannot figure out how to set up the connection to the database dynamicly at run-time using something like app.path.

I'm very familiar with setting up a connection string with ADO objects, but DE objects have me stumped.

Thanks for any help,
Walter Cantrell
 
Walter-

This is what I used in VB-6 in the Data Environment Initialize:

Private Sub DataEnvironment_Initialize()
'Set moveable data connection
conProject1.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.00;" & _
"Persist Security Info=False;Data Source=" & App.Path & _
"\Project1.mdb"
End Sub

Hope this helps.

Tessa
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top