start of a function for the next button