Drag and drop randomly moving obj

hi all ,
i am trying to do a drag and drop game .
i want to have some multiple objects flying randomly around the scene and i want the user to drag and drop them into a box …
when the user drags the same color object for three times into the box
he wins a prize related to that color .

i have solved the drag and drop part like this (thanks to kirupa!!);

on (press) {
startDrag("_root.green" ;
}
on (release) {
stopDrag();
if (_root.green._droptarget == “/computer” {
_root.computer.gotoandStop(“green” ;
_root.pieceCount += 1;
if (_root.pieceCount == 3) {
_root.prize.gotoAndStop(“you won the prize nr 5” ;
}
}
}

so if the user drags the same object for 3 times onto the box he wins a prize related to that object .

and to do the game more challanging i want to make the object to move randomly around the stage ;
so i added this code on the objects ;

onClipEvent (load) {

width = 800;
height = 600;
speed = Math.round(Math.random()*2)+1;
//initial positions
x = Math.random()*width;
y = Math.random()*height;
this._x = x;
this._y = y;
x_new = Math.random()*width;
y_new = Math.random()height;
}
onClipEvent (enterFrame) {
//x movement
if (x_new>this._x) {
sign_x = 1;
} else {
sign_x = -1;
}
dx = Math.abs(x_new-this._x);
if ((dx>speed) || (dx<-speed)) {
this._x += sign_x
speed;
} else {
x_new = Math.random()width;
}
//y movement
if (y_new>this._y) {
sign_y = 1;
} else {
sign_y = -1;
}
dy = Math.abs(y_new-this._y);
if ((dy>speed) || (dy<-speed)) {
this._y += sign_y
speed;
} else {
y_new = Math.random()*height;
}
}

the problem,
both codes work ok when they are seperated …
but together the drag and drop doesnt work … after you click the object remains attaced to the mouse in a strange way …

any ideas please…