If I double-click on a registry key file that contains the following
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\permits_db_conn_new_app]
"Driver"="c:\\Windows\\system32\\sqlncli10.dll"
"Description"="New ODBC Connector for Inspectional Services Permits Applications"
"Server"="ARLINGTON_SERV"
"Database"="BuildingPermit"
"LastUser"="ispermits"
the registry updates properly, and my C# application that uses the DSN permits_db_conn_new_app
works fine.
If I delete that key and then re-create the key using Data Sources (ODBC), that DSN also works fine.
My problem is the first key created by double-left-mouse clicking on the .reg file won't show up in Data Sources (ODBC). I'm trying to figure out why, and I have compared the two keys and found nothing significantly different.
It turns out the little ODBC applet -- Data Sources (ODBC) -- performs one more task after creating a DNS registry entry. It puts an entry for your DSN into [HKEY_CURRENT_USER\Software\ODBC\ODBC.INI\ODBC Data Sources]
, which allows your newly created DSN to show up in Data Sources (ODBC).