Is there such thing as gettotalframes() or getframesplayed()?

As the subject line says. Is thre a way i can track in the beginning how many frames a swf file has played and how many total frames there are. what i want to do is have a swf file contain a song, but somehow be able to track how much of the song has been played and how much is left and i want to be able to create a small bar that moves across. is there a function that will get me “the frames played” and “the total frames” in a swf?