Learn how to loop keyframes without writing any expressions code. The extension iExpressions generates all expressions code for you!
get iExpressions at
http://aescripts.com/iexpressions/
Looping animations in After Effects with iExpressions gives you a lot of control since it works with arbitrary properties and is very easy to do. There are four types of loops that you can choose from:
cycle
seamless
ping pong
offset
When you apply a cycle loop to a position animation, it gets looped before and after the keyframed animation. By default, it loops the region from the first to the last keyframe, although you can also adjust the looped region. The cool thing is - and this goes for all of the loop types - that if you choose to modify the animation a bit, the looped animation gets updated automatically.
When you apply the seamless cycle loop to your animation, the expression will adjust the keyframes to make the animation seamless. So that you get a seamless loop where you would normally get a jumping one.
You can of course loop any other type of keyframes like position, rotation, transparency, text, and so on.
more details:
http://mamoworld.com/after-effects-ex...