Connecting a TSmartQuery to more than one Data Provider and Grid

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Graham_Allan
Posts: 1
Joined: Thu 23 Aug 2007 16:25

Connecting a TSmartQuery to more than one Data Provider and Grid

Post by Graham_Allan » Thu 23 Aug 2007 16:52

Hi All

I'm currently developing a GIS application that interacts with an Oracle database. I'm trying to do something like this:

Database--Query ----Form 1--Data Source-Grid
Table \
\--------Form 2--Data Source-Grid

The idea being that if I edit data in form 1 it is shown as edited in form 2 when I exit the record rather than having to re-query. This currently works but both grids scroll simultaneously.

Is it possible to keep the editing linked but allow the two grids scroll independently? Ideally the active record would still remain highlighted in both grids, even if it’s not visible in one of the forms.

It looks like the cursor position, bookmarking and scrooling through the dataset are controls by the query not the grid - is there any way arround this?

If anyone is familiar with MapInfo I'd like something like the editing that is available there.

Thanks


Graham

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Mon 27 Aug 2007 07:46

The TDBGrid component always positions itself on the current record in the query. When you move the cursor in the TDBGrid component, it changes the current record in the dataset. So it is impossible to scroll throug a DB-grid regardless of the underlying dataset.

Post Reply