chrisjk
Jan 18th, 2000, 10:47 AM
Hi thanks etc
I have a major last-minute problem that I have just noticed...I use ADO Controls extensively in my program...unfortunately, I have just moved the app to my test machine, and the ADO controls are causing problems. It says it cannot find my database!!
I know the ADO control has the path to the database in the ConnectionString property, but I changed this with code when the form initializes. Trouble is...it doesn't work!!
Adodc1.ConnectionString = "Provider=Microsoft.Jet.OLEDB.3.51;Persist Security Info=False;Data Source=" & CurrentDir & "Driving.mdb;Jet OLEDB : Database Password=password"
Adodc1.Refresh
CurrentDir by the way is a variable that is basically App.Path.
The ADO Control appears to be Initialised BEFORE the form is loaded, hence my code to change the connection string is not being executed before it attempts to find the database.
Help - this really sux and I don't know what to do. My boss is ganna blow up when I tell him this!!
Thank you anyone ever so much who gives us a hand!
------------------
- Chris
chris.kilhams@btinternet.com
If it ain't broke - don't fix it :)
[This message has been edited by chrisjk (edited 01-18-2000).]
[This message has been edited by chrisjk (edited 01-18-2000).]
I have a major last-minute problem that I have just noticed...I use ADO Controls extensively in my program...unfortunately, I have just moved the app to my test machine, and the ADO controls are causing problems. It says it cannot find my database!!
I know the ADO control has the path to the database in the ConnectionString property, but I changed this with code when the form initializes. Trouble is...it doesn't work!!
Adodc1.ConnectionString = "Provider=Microsoft.Jet.OLEDB.3.51;Persist Security Info=False;Data Source=" & CurrentDir & "Driving.mdb;Jet OLEDB : Database Password=password"
Adodc1.Refresh
CurrentDir by the way is a variable that is basically App.Path.
The ADO Control appears to be Initialised BEFORE the form is loaded, hence my code to change the connection string is not being executed before it attempts to find the database.
Help - this really sux and I don't know what to do. My boss is ganna blow up when I tell him this!!
Thank you anyone ever so much who gives us a hand!
------------------
- Chris
chris.kilhams@btinternet.com
If it ain't broke - don't fix it :)
[This message has been edited by chrisjk (edited 01-18-2000).]
[This message has been edited by chrisjk (edited 01-18-2000).]