How to delete a DSN? 
Author Message
 How to delete a DSN?

I have code that, given a few parameters (name, driver, etc), will
automatically create a DSN. Trimmed down, it looks like this:

    DBEngine.RegisterDatabase <name>, <driver>, True, <attribs>

It works perfectly. Now, how do I delete it? Since, this code automatically
creates a Registry entry for <name> in
HKEY_CURRENT_USER\Software\ODBC\ODBC.INI, I thought I could try deleting the
Registry entry through code. This works, but I can still see the DSN entry
in Control Panel | ODBC Data Sources.

Is there a way to properly unregister it?

Thanks in advance,

Jonathan Kiefiuk



Sun, 04 Nov 2001 03:00:00 GMT  
 How to delete a DSN?

Hiya, you need to delete the corresponding key value under ODBC.INI\ODBC
Data Sources as well
--
Regards
Pieter Wijnen


http://www.thuleeng.com

Tough guys don't take backup - tough guys cry a lot..

Good site to look for Access answers is:
http://home.att.net/~dashish

  wijnen.vcf
< 1K Download


Mon, 05 Nov 2001 03:00:00 GMT  
 How to delete a DSN?
Sweet! Thank you, Pieter. Exactly what I tried to find but couldn't.
Quote:

>Hiya, you need to delete the corresponding key value under ODBC.INI\ODBC
>Data Sources as well
>--
>Regards
>Pieter Wijnen


>http://www.thuleeng.com

>Tough guys don't take backup - tough guys cry a lot..

>Good site to look for Access answers is:
>http://home.att.net/~dashish



Mon, 05 Nov 2001 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Newbie; create/delete a DSN for MySQL-Databases

2. Crystal and ODBC DSN/DSN-less connections - do I need USER DSN or SYSTEM DSN

3. which Dsn(Data Source Name) is Faster System DSN Or File DSN

4. Deleting a DSN..How?

5. Programmatically deleting DSN using SQLConfigDataSource?

6. DSN System or DSN File ?

7. Connect SQL-SERVER via File DSN or DSN LESS

8. System DSN vs File DSN for Crystal Repots Printing

9. Creating a system dsn or file dsn

10. DSN/ DSN-Less Conenction

11. DSN/ DSN-Less Conenction

12. performance different between DSN to DSN-Less Connection

 

 
Powered by phpBB® Forum Software