X and y slider

Hi
I am trying to create a slider that can slider on both the x and the y axis.
For xample a user may slider a square along a fixed why axis and then be able to slide along a y axis at certain points and so on. I am not sure how tricky this will be - but its an interesting problem

Cheers