Jump to content
  • Advertisement
Sign in to follow this  
Billr17

Retrieving ODBC Settings.

This topic is 4811 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm having some issues grabbing ODBC Settings. First off I need to present a user with the options to select thier DSN, Server, UID, PWD, and Database settings. I have come up with a way using the SQLBrowseConnect function to obtain the Server and Database information I need. Therefore, I have a semi working version of the program. I just need a way to make the program a little more user friendly/fool-proof. I know that there is an option in the ODBC settings to set an default database. I need a way of retrieving this setting and the default server as well. Lastly I would like to turn a text box I am currently using for the DSN name into a dropdown box that contains a list of all available DSNs. What functions are available to help me poll this list? I'm really just interested in those DSN's listed under System DSNs in the Data Source (ODBC). See the below aeticle for the example I used to model my program thrus far: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/odbc/htm/odbcsqlcreatedatasource.asp Let me know if I was not clear in my explains. Any help would be appreciated. Bill

Share this post


Link to post
Share on other sites
Advertisement
FYI: I cross posted this to a Microsoft Newsgroup and got this response:

Quote:

Subject: Re: Retrieving ODBC Settings. 9/12/2005 5:52 PM PST

By: Sue Hoegemeier In: microsoft.public.sqlserver.odbc

You can retrieve the specific settings for a DSN as well as
the existing DNSs by reading the registry - that's where
they are all stored. Check the following key:
HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI

-Sue


Thought that maybe someone would be interested in the answer to my question.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!