Andy Goodman14,206 Points
My code for the additional challenge Guil gave...
See link below for the code I wrote to add/remove the 'up' and 'down' buttons when new items are added/removed or moved.
If anyone is stuck on this, hopefully it can help you. I also removed a lot of repeated code and 'hoisted' the variables to the top of each section.
Birthe Vandermeeren17,140 Points
Nice! I had the same idea of hiding the buttons by setting their visibility to "hidden". My function is different though: first it loops through all buttons in the list to set their visibility to "visible". Then, it sets the visibility of the up button of the first item in the list and the visibility of the down button of the last item in the list to "hidden". So, no ifs and else ifs. I've posted it on the forum too, if you're interested.