PDA

View Full Version : [VB6] Errore metodo OpenRecordset


sunvit
29-11-2004, 13:44
Ho un problema sull'apertura di una tabella di un Database MDB.
Mi dà il seguente errore:
Errore di runtime 13..Tipo non corrispondente
Il codice che ho scritto è il seguente:

Private Sub cmd_Gestione_Click(Index As Integer)
Dim db As Database
Dim rs As Recordset
On Error Resume Next
Set db = OpenDatabase("c:\dati\dati.mdb")
If Err.Number <> 0 Then
MsgBox "Errore nell'apertura del Database"
End If
On Error GoTo 0
Set rs = db.OpenRecordset("Anagrafica", dbOpenTable)
form_inscli.Show
End Sub

Qualcuno è così gentile da aiutarmi?

matpez
29-11-2004, 16:53
Appena arrivo a casa ti mando un esempio dell'utilizzo del database!

matpez
29-11-2004, 18:02
Prova così

sunvit
29-11-2004, 20:00
Provo subito (dopo cena) e ti faccio sapere!
Grazie tante

sunvit
01-12-2004, 22:57
Ho visto solo ora il tuo esempio e ti ringrazio di cuore...Magari se ho bisogno posso chiederti?Mi passeresti la tua mail?
Grazie tante....

matpez
02-12-2004, 20:17
m.pezzin@ublteam.com :)