In the example app, changing the instance of the slider to be a property so can be used outside of the viewdidload method