ado access97 
Author Message
 ado access97

hi - i'm using Access 97 (not running on a database server) and trying
to use ado (although in reading several threads, wonder if this is
adviseable). I've been able to sort of get it to work but now am having
problems with the adodatacontrol. It could be a problem with references
but frankly don't know which ones to add and don't want to just add
randomnly.

THIS WORKS
Dim cnn As New ADODB.Connection
Dim rst As New ADODB.Recordset
Dim fld As ADODB.Field
cnn.Open "Provider=Microsoft.Jet.OLEDB.3.51;" & _
"Data Source=S:\GM
Research\Emrg\Patrizia\Kflows\ISSUANCE\issuanceoutput.mdb;Persist
Security Info=False;"
rst.Open "Select * from Level3", cnn, adOpenForwardOnly,
adLockOptimistic
Do Until rst.EOF
For Each fld In rst.Fields
    If Not IsNull(fld.Value) Then
       MsgBox fld.Value
    End If
Next
Debug.Print
rst.MoveNext
Loop
rst.Close

BUT WHEN I MODIFY
it ever so slightly, to add set the adodatacontrol.recordset = rst, I
don't get an error at run time but it doesn't seem to populate it...
However, I do get a non-fatal error at run time telling me that "No
compatible data source was found for this control. Please add an
intrinsic data control or a remote data control to the form"....

Any ideas  - it's midnight on Sunday in London and I'm hatin' life.
Thanks !!!

Sent via Deja.com http://www.*-*-*.com/
Before you buy.



Fri, 28 Feb 2003 06:57:43 GMT  
 ado access97
Try this

set adodatacontrol.recordset = rst.clone or adodatacontrol.recordset =
rst.clone()


Quote:
> hi - i'm using Access 97 (not running on a database server) and trying
> to use ado (although in reading several threads, wonder if this is
> adviseable). I've been able to sort of get it to work but now am having
> problems with the adodatacontrol. It could be a problem with references
> but frankly don't know which ones to add and don't want to just add
> randomnly.

> THIS WORKS
> Dim cnn As New ADODB.Connection
> Dim rst As New ADODB.Recordset
> Dim fld As ADODB.Field
> cnn.Open "Provider=Microsoft.Jet.OLEDB.3.51;" & _
> "Data Source=S:\GM
> Research\Emrg\Patrizia\Kflows\ISSUANCE\issuanceoutput.mdb;Persist
> Security Info=False;"
> rst.Open "Select * from Level3", cnn, adOpenForwardOnly,
> adLockOptimistic
> Do Until rst.EOF
> For Each fld In rst.Fields
>     If Not IsNull(fld.Value) Then
>        MsgBox fld.Value
>     End If
> Next
> Debug.Print
> rst.MoveNext
> Loop
> rst.Close

> BUT WHEN I MODIFY
> it ever so slightly, to add set the adodatacontrol.recordset = rst, I
> don't get an error at run time but it doesn't seem to populate it...
> However, I do get a non-fatal error at run time telling me that "No
> compatible data source was found for this control. Please add an
> intrinsic data control or a remote data control to the form"....

> Any ideas  - it's midnight on Sunday in London and I'm hatin' life.
> Thanks !!!

> Sent via Deja.com http://www.deja.com/
> Before you buy.



Fri, 28 Feb 2003 15:00:54 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. VB6/ADO/Access97 Security

2. VB6 ADO Access97 and data environments

3. ADO + Access97: please help with AddNew-Method

4. ADO, Access97, and multiple left joins

5. ADO, Access97 and LIKE

6. ADO Access97 Remote Access?

7. ADO, Access97, Sync Problems

8. ADO: Access97 Stored Procedures not supported with OLE DB Jet provider?

9. ARGHH: ADO - Access97 -> fastest provider supporting connection pool

10. ADO: Access97 Stored Procedures not supported with OLE DB Jet provider?

11. Access97 + ADO

12. ADO VB6 Access97 Unable to run Access Query -2147217900

 

 
Powered by phpBB® Forum Software