Read ODBC information from an INI
Hi ,
ODBC information for a particular connection is stored in a particular INI file.I need to read those values from INI file and write it to ODBC registry value.To be precise : I have to read Username and password of a particular ODBC from an INI which is placed in rootdrive.I have to write these values in relevant ODBC registries.
INI looks like
[ODBCINFO]
user= ..
Password= ..
Any help will be appreciated.
ODBC information for a particular connection is stored in a particular INI file.I need to read those values from INI file and write it to ODBC registry value.To be precise : I have to read Username and password of a particular ODBC from an INI which is placed in rootdrive.I have to write these values in relevant ODBC registries.
INI looks like
[ODBCINFO]
user= ..
Password= ..
Any help will be appreciated.
0 Comments
[ + ] Show comments
Answers (11)
Please log in to answer
Posted by:
anonymous_9363
13 years ago
Posted by:
deepak_2007
13 years ago
Posted by:
MSIPackager
13 years ago
Posted by:
deepak_2007
13 years ago
Thanks Rob, That can be done but would appreciate if you could point me to a written custom action coz of my low grip in VB and wise script.
But I am still bothered about ODBC password field. Does this field always remains a manual step ?
Cann't password be set in a INI and read to write in registery ?
I am talking about system DSN so the password must be same for all Users logging in.
Also , cann't ODBC connection through Wise set a password ?
But I am still bothered about ODBC password field. Does this field always remains a manual step ?
Cann't password be set in a INI and read to write in registery ?
I am talking about system DSN so the password must be same for all Users logging in.
Also , cann't ODBC connection through Wise set a password ?
Posted by:
cygan
13 years ago
But I am still bothered about ODBC password field. Does this field always remains a manual step ?
first of all your odbc entries.
do you not access to odbc32.exe where you can create the required odbc settings
for sure you must have the required username and password to create the odbc settings
passwords are not stored in the registry when you create odbc connections
Posted by:
anonymous_9363
13 years ago
Posted by:
deepak_2007
13 years ago
Posted by:
anonymous_9363
13 years ago
Posted by:
deepak_2007
13 years ago
Posted by:
anonymous_9363
13 years ago
Posted by:
elgwhoppo
13 years ago
Deepak, You still haven't specified what kind of ODBC entry this is. If it's a SQL DSN there is no way to store user name and password information in the registry. It either needs to be integrated authentication or SQL authentication. Integrated uses the current logged on user and SQL authentication uses the security accounts set up on the SQL server, and the application needs to pass the username and password to the server.
Why don't you just create the DSN manually and look in the registry to see what it is actually storing? I hate to be the one wheeing in your cheerios, but the concept of using cleartext username and password values in an INI file for DSN creation is a rather poor solution. If the app vendor supports it use integrated authentication.
Why don't you just create the DSN manually and look in the registry to see what it is actually storing? I hate to be the one wheeing in your cheerios, but the concept of using cleartext username and password values in an INI file for DSN creation is a rather poor solution. If the app vendor supports it use integrated authentication.

so that the conversation will remain readable.