logic for next button on entry screen