Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   GUI-Design mit VCL / FireMonkey / Common Controls (https://www.delphipraxis.net/18-gui-design-mit-vcl-firemonkey-common-controls/)
-   -   Delphi Problem mit StringGrid.MouseToCell (https://www.delphipraxis.net/106561-problem-mit-stringgrid-mousetocell.html)

fwsp 12. Jan 2008 19:44


Problem mit StringGrid.MouseToCell
 
hallo,

ich hab ein problem mit MouseToCell. leider ist iCurCol immer 0, egal worauf geklickt wurde. kann mir jmd bei einer lösung helfen?

Delphi-Quellcode:
procedure TfrmMain.StrGridMouseDown(Sender: TObject; Button: TMouseButton;
  Shift: TShiftState; X, Y: Integer);
begin
  StrGrid.MouseToCell(Y, Y, iCurCol, iCurRow);
  if iCurRow = 0 then
  begin
    SortCol := iCurCol;
    ShowMessage(IntToStr(iCurCol) + ' ' + IntToStr(iCurRow));
    SortStringGrid(StrGrid, SortCol);
  end;
end;
//edit
fehler gefunden. :wall:

StrGrid.MouseToCell(X, Y, iCurCol, iCurRow);


Alle Zeitangaben in WEZ +1. Es ist jetzt 12:47 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz