Subject Re: [IBO] How to use a CheckBox in Grid for selecting multiple rows
Author Lucas Franzen

Michael L. Horne schrieb:
> Hello,
> I need to supply a checkbox for the users
> to select multiple rows for processing in
> a query.
> I know how to do it with the CTRL-Click or
> SHIFT-Click but how can I do the same with
> a checkbox. I would prefer to not add
> an additional field to the db.

The only way that coems to my mind is:

Create a TStringList in your form.

Add a calculated field to your query, make all necessary settings for it
to represent a boolean value.

Every time you (un)select a record remove or add the bookmark of the
record of this StringList, and the calculated field will get it's value
from that stringlist, too.

All in all: I prefer the "visual selecting".
You can add some buttons (or a popup menu or whatever) to supply
functions like:
- select all
- select none
- toggle selected
- (un) select current record (which is also bound to the Grid-Dblclick

I think it's easier to see if a record is marked or not that way ...