开发者

C# - How to clear a ListBox's values

How is it possible to clear a ListBox's values, e.g.

    private void clearvalue开发者_StackOverflow中文版s_Click(object sender, EventArgs e)
    {
        <Wipe ListBox1 Values>
    }


I assume you're using WinForms

listBox.Items.Clear();


Use this:

   listBox.Items.Clear();


Try This One

ListBox1.ClearSelection();
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜