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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Adodc question

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
I have a problem.
The DB my app accesses will be installed at the same time as the app. So it will be installed into the same dir as the app (That will be chosen by the user). Now comes the hard part...

I have a few adodc controls on my app, and if the location of my DB will differ from pc to pc, how can I set the connection string for each adodc?

I could easilly do it on code, like:

DBPath = App.path & "\MyDBName.mdb"

Adodc1.ConnectionString = "Provider=Microsoft.Jet.OLEDB.3.51;Data Source= '" & DBPath & "'"

The big problem is that I must set a connection string for the Adodc control at design time!!! And I can't leave it blank so how can I do this? Is there any way of surrounding this?

Maybe i'm just too tired and i'm missing something, but I can't seem to find the way to do this.

Help me out ok ?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top