Zaraq,
YOu either need to detect the mouse move in the parent (this is iffy and not guaranteed to occur) or use a timer object that will reset the picture if the mouse is not over the button when the timer fires.
>I want to change picture1 on a command button with picture2 when the mouse cursor is on that button.I have placed code in the mouse move event to change the picture1 to picture2 but when the mouse cursor moves away from the command button the second picture remains.How do I bring back the first picture on the command button?