Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9241145
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T08:19:06+00:00 2026-06-18T08:19:06+00:00

I have an app in which when user taps on a button it takes

  • 0

I have an app in which when user taps on a button it takes him to a new activity through an animation. The pressed back the previous activity is created again using animation (transition in/out). Doing this fast cause an error.

code:

    startActivity(intent);
            overridePendingTransition(R.anim.slide_in,R.anim.slide_out);
    finish();

Error :

java.lang.IllegalStateException: The specified child already has a parent. You must call removeView() on the child's parent first.
at android.view.ViewGroup.addViewInner(ViewGroup.java:3339)
at android.view.ViewGroup.addView(ViewGroup.java:3210)
at android.widget.ViewAnimator.addView(ViewAnimator.java:184)
at android.view.ViewGroup.addView(ViewGroup.java:3155)
at android.view.ViewGroup.addView(ViewGroup.java:3131)
at com.myapps.tryanim.w.onAnimationEnd(Unknown Source)
at android.view.animation.AnimationSet.getTransformation(AnimationSet.java:400)
at android.view.animation.Animation.getTransformation(Animation.java:940)
at android.view.View.drawAnimation(View.java:13200)
at android.view.View.draw(View.java:13339)
at android.view.ViewGroup.drawChild(ViewGroup.java:2928)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:2797)
at android.view.View.draw(View.java:13710)
at android.view.View.getDisplayList(View.java:12645)
at android.view.View.getDisplayList(View.java:12689)
at android.view.ViewGroup.dispatchGetDisplayList(ViewGroup.java:2910)
at android.view.View.getDisplayList(View.java:12583)
at android.view.View.getDisplayList(View.java:12689)
at android.view.ViewGroup.dispatchGetDisplayList(ViewGroup.java:2910)
at android.view.View.getDisplayList(View.java:12583)
at android.view.View.getDisplayList(View.java:12689)
at android.view.ViewGroup.dispatchGetDisplayList(ViewGroup.java:2910)
at android.view.View.getDisplayList(View.java:12583)
at android.view.View.getDisplayList(View.java:12689)
at android.view.HardwareRenderer$GlRenderer.draw(HardwareRenderer.java:1198)
at android.view.ViewRootImpl.draw(ViewRootImpl.java:2173)
at android.view.ViewRootImpl.performDraw(ViewRootImpl.java:2045)
at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1854)
at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:989)
at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:4351)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:749)
at android.view.Choreographer.doCallbacks(Choreographer.java:562)
at android.view.Choreographer.doFrame(Choreographer.java:532)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:735)
at android.os.Handler.handleCallback(Handler.java:725)
at android.os.Handler.dispatchMessage(Handler.java:92)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:5039)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
at dalvik.system.NativeStart.main(Native Method)

What could be problem here.

slide_in xml-anim

<translate
    android:fromXDelta="100%"
    android:toXDelta="0%"
    android:duration="800" />

slide_out xml

<translate
    android:fromXDelta="0%"
    android:toXDelta="-100%"
    android:duration="800" />
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T08:19:07+00:00Added an answer on June 18, 2026 at 8:19 am

    I figured out the answer myself as the problem was not in the animations, it was with the UI widgets I was adding. So what I did was first removed all the UI widgets and then called the animations so when the new activity starts it has all the UI widgets first removed (if any present) then added again.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an android app on which, when the user taps a TextView ,
in my android app, I have a button that leads to an activity which
I have a flex app which allows user to create some content. this content
I have an android app which let the user to submit a form ,
I have a Flash web app which displays user submitted PNG files. Files are
We have client server based app which saves user related data into a zip
I have a web app which lets the user select the excel spreadsheet and
I have an android app which gives the user the option of loading a
I have an app which access an app folder on a per user basis.
I have an MFC app which is wizard based. The App asks a user

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.