- 人气:
- 放大
- 缩小
- 二维码
- 赞赏
delphi 双击ListBox1内容,数据插入到MEMO1/SynEdit1鼠标指定位置
procedure TfrmMain.ListBox1DblClick(Sender: TObject);
begin
//双击ListBox1内容,数据插入到MEMO1鼠标指定位置
memo1.SelText := ListBox1.Items.Strings[ListBox1.ItemIndex];
memo1.SetFocus;
end;
//SynEdit1 用法一样
procedure TfrmMain.ListBox1DblClick(Sender: TObject);
begin
{ Want to add text to SynEdit to be used with AutoComplete }
SynEdit1.SelText := ListBox1.Items.Strings[ListBox1.ItemIndex];
SynEdit1.SetFocus;
end;