Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 4 of 4 total
Thread Coordinates of a Grid Cell
Fri, Jun 8 2018 3:11 PMPermanent Link

Eivind

All

I am using a ctDialogEditComboBox in a grid. I need to pop up a window where the user can select some values. This should occur once the user starts typing in the cell AND when the button is click. I would like to pop this window up just under the cell itself. I have looked a bit around, but cannot find how to get the X, Y and width of grid cell when starting to type and when clicking the button of the DialogEditComboBox.

Could anyone point me in the direction on how to achieve this?

Thanks

Eivind
Sat, Jun 9 2018 3:12 AMPermanent Link

Uli Becker

Eivind,

<<
Could anyone point me in the direction on how to achieve this?
>>

Maybe there is a better solution, but you can use

RowIndex
ColumnIndex
RowHeight
ColumnHeadersHeight

-properties of TGrid to calculate the position.

Uli
Sun, Jun 10 2018 11:46 PMPermanent Link

Eivind

@Uli

I can see where you are going, and that might work if the grid is not scrolled I guess. Cant say I can figure out how to achieve this when the grid is scrolled. Can we get the Scroll By value and enter this into the calculation?

Eivind
Mon, Jun 11 2018 3:52 AMPermanent Link

Matthew Jones

Eivind wrote:

> I can see where you are going, and that might work if the grid is not scrolled I guess. Cant say I can figure out how to achieve this when the grid is scrolled. Can we get the Scroll By value and enter this into the calculation?

I think it is the RowOffset value, but check.

--

Matthew Jones
Image