By using a spring, you can manage to send the balls from the bottom, to the top, like this:
The yellow object sticks out of the green section a little, and is used to push the spring down. Once released, The spring will launch the ball up. The red line can be pushed down and pulled up to determine where the ball will go.
Feel free to criticize or improve my design, everything helps!