Clear a list box?

How do you clear a list box. I have my results displayed in a list box and I made a clear button but I'm not sure how to clear all the contents in a list box

Comments

  • : How do you clear a list box. I have my results displayed in a list box and I made a clear button but I'm not sure how to clear all the contents in a list box
    :
    Invoke the Clear method: ListBox1.Items.Clear()

  • : How do you clear a list box. I have my results displayed in a list box and I made a clear button but I'm not sure how to clear all the contents in a list box
    :
    Did you mean a textbox?
    if so you would do something like this:

    under the Clear Button in code view you would write

    textboxName.text = "" (what ever you named it)
    hope this helps

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories