本文整理自网络,侵删。
{不重复添加Edit1.text到列表框中} // 调用 ListBoxAddItems(Edit1,ListBox1);
procedure ListBoxAddItems(Edit:TEdit;ListBox:TListBox); begin if ListBox.Items.IndexOf(Edit.Text)<0 then begin ListBox.Items.Add(Edit.Text); Edit.SetFocus; end; end;
相关阅读 >>
Delphi firemonkey在画布上绘制 imagelist图像
Delphi显示 jpg、png、gif 图片及 gif 动画
Delphi android / ios应用程序中使用tgeocoder类进行反向地理编码(从位置信息中获取地址)
更多相关阅读请进入《Delphi》频道 >>