![](/img/trans.png)
[英]How to delete a selected listbox item from both the listbox and the original list in c#
[英]How to delete item from listbox at particular location in C#
如何从特定位置的列表框中删除项目而不是 SELECTED 项目?
比方说,如果我在列表框中有 4 个项目并且我想删除索引 2 处的项目,我该如何在不选择它的情况下执行此操作。
listBox1.Items.RemoveAt(position);
ListBox1.Items.RemoveAt(anyindex);
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.