Skip to content Skip to sidebar Skip to footer

Start Animation Automatically Without The Need Of Click

i know this question has been asked several times but i just cant figure out where to place the code and keep getting errors. its a basic fade in animation on a image which i want

Solution 1:

remove rImage.startAnimation(); from the click listener.

Animationa= AnimationUtils.loadAnimation(this, R.animator.animation);
ImageViewrImage= (ImageView) findViewById(R.id.title);
rImage.startAnimation(a);

Solution 2:

You can use droidQuery to complete the animation:

$.with(rImage).attr("alpha", 0f).animate("{ alpha    : 1.0 }",
                    new AnimationOptions("{ duration : 4000,
                                            easing   : accelerate }"));

Solution 3:

See you cannot start a animation in onCreate, because it is not something that is sticked to main ui, Search more

Here is a link that will help you.

Animation

Post a Comment for "Start Animation Automatically Without The Need Of Click"