Loading animation

How do I make a small animation on the start of my page which only while it loading bytes?

For exaple a litle text that says:

Xbytes of Xbytes loaded

and that the first Xbytes rises while its loaded?

Is it possible to make something like that when waiting for info loading when pressing a meny button?

Im pretty new with flash so I need mucho help.