Seek method, Access97 database, ADO in VB6 
Author Message
 Seek method, Access97 database, ADO in VB6

Hi all,

I am trying to find a solution to a "thorny" problem.
I used to work with DAO to access databases (mostly Jet - Access97), and
when I wanted to find a specific record in the database I would either SQL
it (Select * from Table Where ...) or do a Seek operation, with a predefined
index.

Now, when I try to do the same thing with ADO, I get the following error
message - [Runtime Error 3251: The operation requested by the application is
not supported by the provider]

this happens on my assign of the Index property to "MyIndex".

    If rsSpecMeasur.EOF And rsSpecMeasur.BOF Then
    Else
        rsSpecMeasur.MoveFirst
        rsMeasurName.Index = "MyIndex"
        rsMeasurName.Seek WorkStageNum & "-" & rsSpecMeasur!MeasurementNum
        If Not rsMeasurName.EOF Then
            GetData
        End If
    End If

Please don't tell me that I need to upgrade to Access 2000 in order for this
very simple code to run??

Thanks a mill,
Rimon Rafiah



Sat, 07 Dec 2002 03:00:00 GMT  
 Seek method, Access97 database, ADO in VB6

Quote:

<snip>
> Now, when I try to do the same thing with ADO, I get the following error
> message - [Runtime Error 3251: The operation requested by the application is
> not supported by the provider]

> this happens on my assign of the Index property to "MyIndex".

>     If rsSpecMeasur.EOF And rsSpecMeasur.BOF Then
>     Else
>         rsSpecMeasur.MoveFirst
>         rsMeasurName.Index = "MyIndex"
>         rsMeasurName.Seek WorkStageNum & "-" & rsSpecMeasur!MeasurementNum
>         If Not rsMeasurName.EOF Then
>             GetData
>         End If
>     End If

  I don't think you need to use A2K db's, but you need to be sure your
ADO code has the correct specifications when you Open the recordset.  I
haven't tested it, but you might find help in the the ADO code at
http://support.microsoft.com/support/kb/articles/Q243/4/65.ASP - with
Acess97, your .Provider could be Jet.OLEDB.3.51 (even tho it sez it's
for A2K, the ADO code would be applicable to VB6).
--
Jim in Cleveland
If you're writing to me, in my address
change "REAL_Address.see.below" to "worldnet.att.net"
 ((("What's so funny 'bout peace, love & understanding?" - Nick Lowe)))


Sat, 07 Dec 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Creating an ADO VB6 stand-alone database program (Newbie seeks advice)

2. FIND method using ADO 2.5+ VB6 and SQL database

3. Using Seek Method in VB6

4. ADO Index property and Seek method

5. Index Property/SEEK method Problem with ADO

6. Seek method on ADO data recordset?

7. ADO and Seek Method

8. "Seek" method with ADO

9. Seek method (ADO)?

10. ADO Recordset Object, Seek Method

11. Seek method in ADO

12. ADO 2.1 Seek method

 

 
Powered by phpBB® Forum Software