Dear Sirs,
I could not understand vb.net database connection statements for access.mdb.
I was using following procedures with vb 6 without problem. But I can not
find same solution for vb.net For example I can not get any data with;
adoPrimaryRS!Gu rup.
I try to find somehing on msnds, but no result. What should I do? where can
I find solutions
Best Regards
Dim adoPrimaryRS As Object
Dim db As ADODB.Connectio n
db = New ADODB.Connectio n
db.CursorLocati on = ADODB.CursorLoc ationEnum.adUse Client
db.Open("PROVID ER=Microsoft.Je t.OLEDB.4.0;Dat a Source=" & VB6.GetPath &
"\ber.mdb;" )
adoPrimaryRS = New ADODB.Recordset
adoPrimaryRS.Op en("select DISTINCT Gurup from Rehber Order by Gurup", db,
ADODB.CursorTyp eEnum.adOpenSta tic, ADODB.LockTypeE num.adLockOptim istic)
Do While Not adoPrimaryRS.EO F
If Not IsDBNull(adoPri maryRS!Gurup) Then
cmbGurup.Items. Add(adoPrimaryR S!Gurup)
End If
adoPrimaryRS.Mo veNext()
Loop
I could not understand vb.net database connection statements for access.mdb.
I was using following procedures with vb 6 without problem. But I can not
find same solution for vb.net For example I can not get any data with;
adoPrimaryRS!Gu rup.
I try to find somehing on msnds, but no result. What should I do? where can
I find solutions
Best Regards
Dim adoPrimaryRS As Object
Dim db As ADODB.Connectio n
db = New ADODB.Connectio n
db.CursorLocati on = ADODB.CursorLoc ationEnum.adUse Client
db.Open("PROVID ER=Microsoft.Je t.OLEDB.4.0;Dat a Source=" & VB6.GetPath &
"\ber.mdb;" )
adoPrimaryRS = New ADODB.Recordset
adoPrimaryRS.Op en("select DISTINCT Gurup from Rehber Order by Gurup", db,
ADODB.CursorTyp eEnum.adOpenSta tic, ADODB.LockTypeE num.adLockOptim istic)
Do While Not adoPrimaryRS.EO F
If Not IsDBNull(adoPri maryRS!Gurup) Then
cmbGurup.Items. Add(adoPrimaryR S!Gurup)
End If
adoPrimaryRS.Mo veNext()
Loop