Help with conditionals AS2

I’m trying to limit the range with which a movieclip can be moved on the stage using the mc_name._y = mc_name._y + 10.

I’m thinking of using a if/else statement but I can’t figure out the proper way to write the code.

I don’t want my movieclip to be able to be moved off the stage completely.

Any help would be much appreciated.

Thanks,
Will
Source files are too big to attach, but can be downloaded here:
http://194.170.242.235/golf/golf2.gz.zip

. Here is the code so far:

zoomin.onRelease = function () {
tellTarget(“a”)
{
nextFrame();
}
}

zoomout.onRelease = function () {
tellTarget(“a”)
{
prevFrame();
}
}
up.onRelease = function () {
a._y = a._y + 10;
}

down.onRelease = function () {
a._y = a._y - 10;
}

left.onRelease = function () {
a._x = a._x + 10;
}
right.onRelease = function () {
a._x = a._x - 10;
}