Coba seperti ini, saya pernah dapat coding seperti berikut, sorry saya lupa 
sitenya, moga membantu:

Sub OracleConnect()
    On Error GoTo logonError
    Dim Conn As String
    Dim drv As String
    uid = Trim$(frmLogon.txtUserId.Text)
    pwd = Trim$(frmLogon.txtPassword.Text)
    dBase = Trim$(frmLogon.txtDatabase.Text)
    Set db = New ADODB.Connection
        With frmLogon
        
            If .txtUserId.Text = "" Then
                MsgBox "Please Enter USER ID", vbExclamation
                .txtUserId.SetFocus
                Exit Sub
            ElseIf .txtPassword.Text = "" Then
                MsgBox "Please Enter Password", vbExclamation
                .txtPassword.SetFocus
                Exit Sub
            End If
            
            If .txtDatabase.Text <> "" Then
                Conn = "UID= " & uid & ";PWD=" & pwd & ";DRIVER={Microsoft ODBC 
For Oracle};" _
                & "SERVER=" & dBase & ";"
            Else
                Conn = "UID= " & uid & ";PWD=" & pwd & ";DRIVER={Microsoft ODBC 
For Oracle};"
            End If
        End With
        
        Screen.MousePointer = vbHourglass
        With db
            .ConnectionString = Conn
            .CursorLocation = adUseClient
            .Open
        End With
        Screen.MousePointer = vbDefault
logonError:
    If Err.Number <> 0 Then
        Screen.MousePointer = vbDefault
        MsgBox "If Any Error Occured Please Restart the Prog If Reqd. Error 
Description:" & Err.Description & "", vbCritical
        
        With frmLogon
            .txtUserId.Text = ""
            .txtPassword.Text = ""
            .txtDatabase.Text = ""
            .txtUserId.SetFocus
        End With
    
    Else
        Screen.MousePointer = vbDefault
        Unload frmLogon
        frmMain.Show
    End If
    
End Sub



----- Original Message ----
From: Christopher Rodjito <[EMAIL PROTECTED]>
To: [email protected]
Sent: Friday, April 11, 2008 8:09:51 PM
Subject: [indoprog-vb] connect database di VB lewat oracle connection

salam, para master VB. 
Mau nanya nih buat tugas skripsi, gimana caranya biar kita bisa bikin software 
database pake VB6 dengan connection menggunakan oracle.

Ada yang bisa bantu ?

Thanks a lot yah sebelumnya.. .

____________ _________ _________ _________ _________ _________ _ 
Yahoo! For Good helps you make a difference 

http://uk.promotion s.yahoo.com/ forgood/

[Non-text portions of this message have been removed]


 

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

[Non-text portions of this message have been removed]

Kirim email ke