Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2004.05.30;
Скачать: CL | DM;

Вниз

MouseToCell в TdxDBGrid - как реализовать?   Найти похожие ветки 

 
Lexa_1   (2004-05-13 15:01) [0]

Как можно в компоненте TdxDBGrid определить координаты ячейки, над которой находится курсор мыши? На пример, в StringGrid"е аналог - MouseToCell.


 
MU   (2004-05-13 15:08) [1]

см
dxDBGrid1.GetHitInfo
dxDBGrid1.GetHitTestInfoAt


 
MU   (2004-05-13 15:11) [2]

procedure TForm1.dxDBGrid1MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
var
 G: TdxDBGrid;
 P : TPoint;
 Col : TdxDBTreeListColumn;
 HitTest: TdxTreeListHitInfo;
begin
 G := Sender as TdxDBGrid;
 P.x := X; P.y := Y;
 HitTest := G.GetHitInfo(P);
 G.Hint := "";
 if HitTest.hitType = htColumn then
 begin
   Col := G.GetColumnAt(X, Y);
   if Col <> nil then
     G.Hint := "Column: " + Col.Caption;
 end;
 if HitTest.hitType = htSummaryFooter then

 begin
   Col := G.GetFooterColumnAt(X,Y);
   if Col <> nil then
     G.Hint := "Symmary: " + Col.Caption;
 end;
 if HitTest.hitType = htSummaryNodeFooter then
 begin
   Col := G.GetNodeFooterColumnAt(X,Y);
   if Col <> nil then
     G.Hint := "Node Symmary: " + Col.Caption;
 end;
 if G.Hint <> "" then
   G.Showhint := True
 else
   G.ShowHint := False;
end;


 
Lexa_1   (2004-05-13 15:21) [3]

спасибо



Страницы: 1 вся ветка

Текущий архив: 2004.05.30;
Скачать: CL | DM;

Наверх




Память: 0.47 MB
Время: 0.026 c
3-1084362480
Basaur
2004-05-12 15:48
2004.05.30
технология DataSnap


14-1084023239
SPeller
2004-05-08 17:33
2004.05.30
PE Viewer 1.1 (нужна помощь)


8-1079717600
Beginner1
2004-03-19 20:33
2004.05.30
Как можно разбить картинку?


3-1084107044
Cardinal
2004-05-09 16:50
2004.05.30
Присвоение значения полю. Проблема.


1-1084859905
dim-
2004-05-18 09:58
2004.05.30
получить результат из dll