ado and .ini files
-
Hi there, I need some help with ADO. Right now i have a program written in VB using ADO. I have the connection string hard coded to a specific database. How do make it so the ado will look in an ini at the second line and change the connection string to the one in the ini file. Do i have to remove the connection string in the program? Please help.
-
Hi there, I need some help with ADO. Right now i have a program written in VB using ADO. I have the connection string hard coded to a specific database. How do make it so the ado will look in an ini at the second line and change the connection string to the one in the ini file. Do i have to remove the connection string in the program? Please help.
If the connection string has been entered into a property in the properties window, you will need to delete it. Then, you will have to read in the ini file yourself (using either standard file access methods, or GetPrivateProfileString API call) and set the ConnectionString property to be the string that is read out. ADO wont automatically go looking in an ini file. -- David Wengier Sonork ID: 100.14177 - Ch00k