index > .NET Framework Data Access and Storage > Requesting a list of datasources in vs 2005 and VB

Requesting a list of datasources in vs 2005 and VB

I'm trying to provide a way for the end user to select an ODBC datasource from the available datasources on the machine.

I've searched the net, many books, and available documentation and am now at a loss.

Can someone point me in the right direction?

d



ducky242

I found one way to do this. Basically, I read the registry keys under the ODBC section. Not glamorous, but functional. You would think there would be a function call in .net.

d

ducky242

I believe DbProvideFactory class allows you to get list of the data sources. Check next link in MSDN

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnvs05/html/vsgenerics.asp




Val Mazur (MVP) http://xport.mvps.org
VMazur
reply 3

You can use google to search for other answers

 

More Articles

• FAQ
• Dinamically adding columns
• Open DataReader associated with this Command
• got a form, got a database, the two don't talk
• Com Exception is unhandeled while executing ExecuteReader
• Selecting / Update records - Concurrancy
• writing image into word document in asp.net 2.0
• transaction scope with oracle produces a distributed transaction?
• Adding shortcut key to TabControl
• SqlConnection object and garbage collection
Bookmark and Share
Welcome to Bokebb   New Update  
 

New Articles

• No value given for one or more required
• streamreader+inserting/updating the rows
• OdbcConnection problem
• You help will be appreciated: Connection
• Retrieving @@Identity from Access databa
• Query a View
• SQL select with variable or an object
• Returning DataReaders
• Client-side redirect problem
• How to force a single line per data in a
• error connecting using the config file
• .Net 2.0 Web App linking to SQL 2000
• detailview "Tipi di dati non corris
• DataGridView Detail Row Saving
• Help C# SQLTABLES

Hot Articles

• Accessing ADO .Net DLL from C++ code
• return output Inserted.ColName value int
• Performance problem with DataSet.Relatio
• About Connection and Disconnected Archit
• Updates Using the Entreprise Library DAAB
• Problem with calculated column - does no
• Errors creating new data source
• Concurrency Violation on 2 of 3 linked s
• table adapters - update
• How to get Database information in ASP.NET
• Problem Enumerating Sql Server Using Sys
• Embarrassing Problem with inserting reco
• ADO.NET vNext : System.Data.DataRowView
• Using classic ADO parameter objects from
• Query a View

Recommend Articles

• ODBC TableAdapter Updating
• ExecuteNonQuery not working within CLR S
• DataView with DateTime comparation
• Importing into SQL Server 2000 from XML
• ODBC or OLEDB
• What is the best way to handle null valu
• How can i use SqlTransaction with TableA
• Visual C++ .NET Oracle connection error
• Where to store SQL server connection str
• Error opening a sample .mdf database
• -Using Sproc to insert rows in the DB an
• SQL Server Procedure call timeout from .
• delete and update code at the same butto
• DataSet thread safety
• - Is there a difference between Dataread