Login  

Blog Stats

News


Visual Developer - Visual Basic MVP

隨筆分類

文章分類

每月文章

優質好站連結


強力鎯頭 の VB 部落

歡迎蒞臨 Power Hammer の VB 部落 ! J 裡會放一些 VB .Net Oracle Crystal Report 等相關資訊分享給大家囉..

 

VB.Net 如何列舉電腦中所安裝的 ODBC Driver

 

' 由登錄檔讀取電腦中所安裝的 ODBC 驅動程式

 

Imports Microsoft.Win32

 

Public Class Form1

 

    Private Sub Button1_Click(ByVal s As Object, ByVal e As EventArgs) Handles Button1.Click

 

        Dim RegKey As RegistryKey = _

            Registry.LocalMachine.OpenSubKey("Software\ODBC\ODBCINST.INI")

 

        ListBox1.Items.Clear()

 

        For Each drv As String In RegKey.GetSubKeyNames

            ListBox1.Items.Add(drv)

        Next

 

    End Sub

 

End Class

 

列舉電腦中所安裝的 ODBC Driver

 

 

posted on Sunday, October 21, 2007 11:05 PM

What People Are Saying About This Post...

No comments posted yet.

What do you have to say?

Title:
Name:
Url:
驗證碼  
Comments: