TAdvStringGrid or TDBAdvGrid and transforming data

I need to display (but not edit) some data from an SQL Lite database in a grid. I also need the ability to decode some of the rows before they get displayed (for example, one column is stored in base64 format, I'd like to convert it to readable text before displayed).


Couple of questions:
  • Does TDBAdvGrid provide a hook or event to transform the data between data retrieval and cell rendering?
  • If TDBAdvGrid doesn't handle it, I'll have to resort to TAdvStringGrid. Is there a way of populating the cell data on demand (rather than pre-populating all the Cells property)

(forgot to subscribe)

Have you considered handling this in the event OnGetDisplText?

I had not Bruno, thank you for the suggestion. I was thinking I would try to modify the TDataset before I assigned it to the grid, but your suggestion sounds easier. Thank you!!


One other question. There's probably a way of doing this this that I'm just not familiar with, but is it possible to alternatively change the background colors of the rows?

Yes, you can have this with setting grid.Bands.Active = true.

Thank you Bruno!