Home Technical Talk

Autodesk 3ds Maxscript: How to delete all items from a list box?

polycounter lvl 6
Offline / Send Message
MrQuetch polycounter lvl 6
Hello.

In Maxscript, I have learned how to append and delete items one by one in a list box without problems. Now, I want to delete every object in a list box with the click of a button. I have looked everywhere for answers on this subject with unfortunately no luck. Although some topics have been close to this, they haven't been exact. I assume that this is an easy fix, and I really didn't want to have to make a thread... But, I still can't figure this out.

I appreciate everything. Thanks.

Replies

  • Mark Dygert
    Options
    Offline / Send Message
    Inside of the button clicked argument you set the listbox array to be nothing. So 

    on MyResetButton pressed do (<br>listbox.items = #()<br>)
  • MrQuetch
    Options
    Offline / Send Message
    MrQuetch polycounter lvl 6
    Inside of the button clicked argument you set the listbox array to be nothing. So 

    on MyResetButton pressed do (<br>listbox.items = #()<br>)
    I apologize for my late reply. Thank you so much for your help, Mark.

    I can't believe I didn't think of that in the first place - it was only obvious. That was a very simple fix.
Sign In or Register to comment.