Hello the example dosen't work.
SelectionMode is smSingleRow
How can i find the rowindex of the selected row in the Grid?
I try two way's, but nothing works:
function SelectRowCol():integer;
var i : integer;
begin
for i := 0 to sgAnlage.RowCount - 1 do
begin
if sgAnlage.RowSelect then begin
result := i;
exit;
end;
end;
end;
function SelectRowCol2():integer;
var i, rowindex : integer;
begin
result := 0;
for i := 0 to sgAnlage.RowSelectionCount - 1 do begin
result := sgAnlage.SelectedRow; // do something with the selected row rowindex here
exit;
end;
end;
Regards
Axel