如何将列表框中当前添加的项目作为第一项 [英] How to make currently added items in the listbox as first item

查看:75
本文介绍了如何将列表框中当前添加的项目作为第一项的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

hi
i我在列表框中添加了一些项目。我想显示列表框中添加的最后一项

作为列表框中的第一项如果有人知道怎么做的话帮助我。

提前感谢

hi i am adding some items in the listbox .i want to display the last item added in the listbox
as first item in the listbox if anyone have any idea how to do it help me.
thanks in advance

推荐答案

使用ListBox.InsertItem [ ^ ]


你尝试过这样的事情:

Have you tried something like this:
ListBox1.Items.Insert(0, "New Item On Top");







有关详细信息,请参阅: ItemCollection.Insert方法 [ ^ ]


这篇关于如何将列表框中当前添加的项目作为第一项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆