An example on how to make a scrollbar, which automatically adapts itself on changing array count.
Press "Enter" to add or "Delete" to remove items. You can use either your mouse wheel or a mouse click and release to change the scroll value of the scrollbar.