Dear developers,
I've got an issue with ExpressQuantumGrid.
I want the rows to change color whenever the user moves the mouse over
them.
I've deeply searched on the Internet but found nothing interesting.
Seems that nobody needs to do that, but I find it so obvious and
simple!
Editing some examples found in the Internet, I made this solution:
procedure
TMainForm.MainGridMouseMove(Sender: TObject;
Shift: TShiftState; X, Y: Integer);
var
Site: TcxGridSite;
HitTest: TcxCustomGridHitTest;
Item: TcxCustomGridTableItem;
Rec: TcxCustomGridRecord;
begin
Site := Sender as TcxGridSite;
HitTest := Site.GridView.ViewInfo.GetHitTest(X, Y);
if HitTest is TcxGridRecordCellHitTest then
begin
Rec := TcxGridRecordCellHitTest(HitTest).GridRecord;
Rec.Focused := True;
end;
end;
The problem is that only ONE cell is selected, and not the whole row.
You might say me "so disable cell select". But this means
disabling cell editing. There are some checkboxes in the grid, and if
I disable cell editing, those checkboxes become inactive.
What can I do?
Thank you in advance! :D


|