请问stringgrid如果获取当前选择的行

conis 2005-03-28 11:20:21
不用onSelectCell事件
我用菜单(N1.Click)事件
...全文
535 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
tgtcn 2005-04-21
  • 打赏
  • 举报
回复
stringgrid.row即为当前行
sharon_lee 2005-04-07
  • 打赏
  • 举报
回复
的确是有row这个属性,表示当前选中的行
同时还有col这个属性,表示当前选中的列
conis 2005-03-28
  • 打赏
  • 举报
回复
没有Row这个属性
Kshape 2005-03-28
  • 打赏
  • 举报
回复
procedure TForm1.StringGrid1DblClick(Sender: TObject);
var
Rowindex,ColIndex:integer;
begin
//StringGrid1.Options:=StringGrid1.Options+[goEditing];
Rowindex:= StringGrid1.Row; //获取行索引
ColIndex:= StringGrid1.Col;//获取列索引
showmessage( Inttostr(Rowindex)+': '+ Inttostr(ColIndex))
end;
shxyz 2005-03-28
  • 打赏
  • 举报
回复
stringgrid.row即为当前行呀
肥仔胧 2005-03-28
  • 打赏
  • 举报
回复
就是Row这个属性啊!!!

16,749

社区成员

发帖
与我相关
我的任务
社区描述
Delphi 语言基础/算法/系统设计
社区管理员
  • 语言基础/算法/系统设计社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧