Delphi/CB
•  Greatis •  Security •  AppDatabase •  Utilities •  Visual Basic • .NET •  just4fun
Delphi / C++ Builder
Components, utilities and tips for Delphi and C++ Builder developers
Hot Offer
Save your money!
Featured
Ultimate Pack  hot!
Image Editor  new!
Runtime Fusion
Form Designer
Object Inspector
Print Suite Pro
Commented Image
Delphi Toys
WinDowse
Delphi Bonus
TMS Scripter Studio
Form Designer VB
Form Designer .NET

...get more...
for Delphi.NET, C#, VB.NET
for Delphi VCL, BCB 3-6

News Tips .NET Software VCL Software Partners  

Set hint for cells of StringGrid
This example shows, how to check a cursor moving in StringGrid component and how to show hint for each cell with coordinates of this cell.

procedure TForm1.FormCreate(Sender: TObject);
begin
  StringGrid1.Hint:= '0 0';
  StringGrid1.ShowHint:= True;
end;

procedure TForm1.StringGrid1MouseMove(Sender: TObject; Shift: TShiftState;
  X, Y: Integer);
var
  R, C: Integer;
begin
  StringGrid1.MouseToCell(X, Y, C, R);
  with StringGrid1 do
  begin
    if ((Row<>R)or(Col<>C)) then
    begin
      Row:=R;
      Col:=C;
      Application.CancelHint;
      StringGrid1.Hint:=IntToStr(R)+#32+IntToStr(C);
    end;
  end;
end;

For more
Delphi Help

Download source


Our Partner
DevArchive.com
Recommended
just4fun
Useful Resources
Win32.hlp Online
Unix Manual Pages
MegaDetailed.NET
in3steps.com
Newsletters
Subscribe to our news!    Subscribe to our news!


Greatis Software Greatis | Security | AppDatabase | Utilities | Delphi/CB | Visual Basic | .NET | just4fun

Contacts | Add to Favorites | Recommend to a Friend | Privacy Policy | Copyright © 1998-2008 Greatis Software