Cannot apply an action script

hi…
i was using flash 8 before and now im using flash CS3.
i have created a movie clip and i want to insert this code:


on (release) {
 iColor=new Color(this);
 iColor.setRGB(_root.fillColor);
 delete iColor;
}

but when i click on the movie clip and go to Actions this what appears:
Current selections cannot have actions applied to it…
but in flash 8 i can put the code in the movie clip…
can someone please teach me how to do this in CS3…
thankx