Recent

Author Topic: Button with image or caption in a DBGrid column line?  (Read 374 times)

babycode

  • New Member
  • *
  • Posts: 38
Button with image or caption in a DBGrid column line?
« on: November 12, 2024, 07:14:28 pm »
Good afternoon, is it possible to add buttons to rows in a DBGrid column? The idea is that the buttons appear next to the records so that, when clicked, it takes the code from the selected record and adds it to another dataset. I saw that there is a column property that defines the ButtonStyle and creates this button within the column, but I don't see the possibility of changing the caption or adding an image to it. Is there any other way?

jamie

  • Hero Member
  • *****
  • Posts: 6735
Re: Button with image or caption in a DBGrid column line?
« Reply #1 on: November 13, 2024, 01:38:37 am »
yes, it's possible, if you look around that has already been covered.

Using the "OnDrawColumnCell" event, you can draw an image over the button or whatever.

The only true wisdom is knowing you know nothing

 

TinyPortal © 2005-2018