[Flash8] frame function

Hi, Just a quick question, probably easy as anything but that’s me for u. I’m trying to use an if statement on a frame, but it doesn’t seem to work do i need to put into some sort of function? any help?