Главная страница | назад





Article #27579: How to use TADOTable Seek procedure.

QUESTION:

     When I use TADOTable.Seek I get an access violation, "Object or provider is not capable of performing requested operation." In the help it is documented that all I need is Access 2000 and the Jet 4 Provider. How do I get Seek to work?

ANSWER:

     The online help is slightly miss documented for this procedure. There are two other properties that need to be set in order to successfully execute the seek procedure. You can download a demo project from Code Central here.

To avoid the access violation you have to set two properties for TADOTAble. The first is to set CursorLocation := clUseServer. The second step is to set the TableDirect property to True. You can also specify the IndexName property to be the primary key of the table, but this seems to be optional.

Last Modified: 04-AUG-01